|
Hi,
I want the details of IE window as soon as IE window is opened either by double clicking from Desktop icon or from Start menu. So is there any event which gets fired when the IE window is opened which I can capture in my program. My program will be a Windows service written in C#.
Please let me know how it can be done.
Thanks in advance.
Sunil
|
|
|
|
|
Here is a function I wrote that checks if Internet Exlplorer is running and if it is, the function returns true. You can put this function in a function of a Timer class that executes the IsExplorerRunning function at a specified interval - therefore checking every let's say 100 milliseconds. Let me know if you have any questions.
Make sure you include System.Diagnostics:
using System.Diagnostics;//put at the beginning
//put function in class
private bool IsExplorerRunning()
{
Process[] myProcess = Process.GetProcesses();
int i = 0;
try
{
while (myProcess[i] != null)
{
if (myProcess[i].ProcessName.ToUpper() == "IEXPLORE")
{
int i2 = 0;
try
{
while (myProcess[i2] != null)
{
myProcess[i2].Close();
i2 += 1;
}
}
catch { }
return true;
}
i += 1;
}
}
catch { }
int i3 = 0;
try
{
while (myProcess[i3] != null)
{
myProcess[i3].Close();
i3 += 1;
}
}
catch { }
return false;
}
|
|
|
|
|
Hi,
Thanks for your solution. But won't it slow down the system running this code every 100 milliseconds?
Regards,
Sunil
|
|
|
|
|
It works fine on my computer, but I agree there should be a more efficient way of checking. Note the function doesn't contain the code for the Timer object - you can add that to it if you need to. This function checks if Internet Explorer is running. There should be another function which invokes this (IExplorer checking function) The Process object doesn't seem to have a function that checks if a program has started running. If you find a class that has a function that checks that, you don't need the Timer object function to check every so milliseconds.
|
|
|
|
|
I may be wrong but I think if you create a new instance of the internet explorer object and one already exists it will take ownership of the running process
as for the timer object, I would instead start a running thread and set it to sleep for an acceptable durration of time, upon waking it does the check.
|
|
|
|
|
I agree about the thread sleep solution. I didn't have it on a thread though, but it would be better to have it on a separate thread. This was just an example - if you want to you can modify the function so it accepts a ref parameter. Then pass your existing object as a ref parameter to this function.
|
|
|
|
|
I am using C# 2005 beta version. My problem is whenever I stop my code through a breakpoint while debugging the tooltips shown for the functions definations get bold and it remains bold afterwards for ever untill i restart my computer. I am too irritated with this bug. Do anyone know the solution to this problem.
Thanks in advance.
Regards
Sheel
Sheel Gohe
|
|
|
|
|
|
Just searched Google and this message bord without success. Therefore my question:
Is there a GUI library available (both, commercial or free) for creating Windows Forms applications with Windows Forms 2.0?
I'm looking for more advanced controls than currently present in the standard set, like the Visual Studio 2005 IDE uses itself (floating, attachable Windows etc.).
Thanks
Uwe
--
Affordable Windows-based CMS for only 99 €: try www.zeta-producer.com for free!
|
|
|
|
|
|
Thanks, Leppie!
I'm just browsing now...
Did you find any specific? The best would be to have a native .NET version of the great Codejock "Xtreme Command Bars" which I am using successfully for MFC already.
--
Affordable Windows-based CMS for only 99 €: try www.zeta-producer.com for free!
|
|
|
|
|
I was looking for a pretty and free docking control, but couldnt find any. Daniel from #dev suggested DockPanelSuite, which seems ok, but a but buggy and resource hungry. I did see various companies do the VS2005 style docking (which is vewy pwetty)
xacc.ide-0.1.1 released! :) Download and screenshots
|
|
|
|
|
you can also try look at NetAdvantage from Infragistics. I downloaded the trial version from the website and their docking windows is exactly like in VS 2005. Its pretty easy to use.
-- modified at 20:07 Tuesday 27th December, 2005
didnt realise infragistics gui tool is posted under http://www.devdirect.com/
|
|
|
|
|
Hi,
I have an desktop win application by c#.(not ASP.net app)
And I want other users to launch it from internet browser,
just like launch MS Word from IE, or launching it like
java applet from web page. What should I do to the c# code
so that it can behave like that ? Is it similar to the concept of web application ? How many ways can I adopt to achieve it ?
And how can the c# app to communicate with the web page that
it is launched ?
Thanks
|
|
|
|
|
vs 2005 has the right property set called "Click once" deployment which enhances winforms application versioning and deployment. By publishing it on a web server; your application will be accessible on a link... read my article on this search as "vwd"
Mikail Çetinkaya . The C# DEveloper
|
|
|
|
|
How can I convert a byte array to a double array FAST?
/\ |_ E X E GG
|
|
|
|
|
Answered here.
Hope this helps!
|
|
|
|
|
|
Dear all,
How I can flush sql connection pool in C#. Please give me C# code for it.
With Regards
Manoj
|
|
|
|
|
Hi all,
Can anyone please tell me how to enter text in a Rich Edit control in C#. Is it just the plain
richEdit1.text += "This is a string";
Actually i wanted to know if there is some other way around so that i can format the text while inserting it into the Rich Edit. Somthing like i fix a particular format, then enter the text so that it appears in that format, and then change the format and enter text so that it appears in a different format.
Is it possible.. ?????
Please help me with this....
Thanks in advance.
*** Who said nothing is impossible? I have been doing it for a long time ***
|
|
|
|
|
|
Thanks man...!!!!!
that was a real help... really cool.
I hope there are similar methods to change the font attributes.
Can you also tell me how to embed an image into it. i forgot to mention this while posting the message.
Thanks in advance.
*** Who said nothing is impossible? I have been doing it for a long time ***
|
|
|
|
|
richTextBox1.AppendText("AHHAHAHA");
This appends the text adds the text to the already existing text.
rickTextBox1.Text = "OHOOHOH";
Replaces the text whole text of the richtextbox rather than add to it.
Not sure which one you wanted.
http://www.codeproject.com/cs/miscctrl/csexrichtextbox.asp
|
|
|
|
|
Thats great..
I'll try that and let you know if it worked.
Thanks a lot.
*** Who said nothing is impossible? I have been doing it for a long time ***
|
|
|
|
|
In MDI Application, anyhow to do, the Maximize Button still exist,Can let it to not display? How to do it? Give me a sample.Thanks.
|
|
|
|