Problem while clicking link(Win Forms)
Hi Friends,
I have one win form where there is a one labellink. When i click on that link it opens pop up window in IE7 explorer. When you click on same link it opens another pop up tab in IE. But i have to avoid that. When you click on that link it should display same tab which is already opened instead of creating new tab. I have tried with
Code:
System.Diagnostics.Process proc
and i have written code like this
Code:
try
{
if (proc.HasExited)
{
proc =
Process.Start("iexplore.exe", "www.google.com");
}
else
{
MessageBox.Show("Window is Already Opened!!");
}
}
catch
{
proc = Process.Start("iexplore.exe","www.google.com");
}
But here the problem is when you close opened tab and keep another empty tab , click on that link it says that Message already opened.
I dont know how to solve this. Please give me solution if you know this..
Thanks in advance..
Re: Problem while clicking link(Win Forms)
Here is a good example which shows you two ways to enumerate through each open IE tab.
http://www.eggheadcafe.com/community...ys-that-i.aspx
That said, you should be using the user's preferred browser, not strictly IE. Of course, that would make this more difficult :).