Starting a new Internet Explorer process and connecting to it

F

Federico Cozzi

Hello,
in my VB.net I would like to
1) start a new Internet Explorer process (not a new window of the
running process)
2) and connecting to its WebBrowser control, or InternetExplorerClass,
afterwards.

Basically, creating a new WebBrowser doesn't work because it opens a
new window of the running Internet Explorer, but if I start a new IE
process (with System.Diagnostics.etc..) I don't know how to use it "as
a browser" from my code.

I suppose I should just start a new IE process and then connect to it
using some kind of magic, but:
a. how can I find the IE *I* just started, in a reliable way? I am not
sure that checking for its URL is reliable enough... is there some
sort of process ID to look for?
b. when I find it, how do I "cast" it to my desired object?

As you can see I am really a newbie Windows programmer... (I come from
a Unix background)

Thanks,
Federico
 
L

Lloyd Sheen

Federico said:
Hello,
in my VB.net I would like to
1) start a new Internet Explorer process (not a new window of the
running process)
2) and connecting to its WebBrowser control, or InternetExplorerClass,
afterwards.

Basically, creating a new WebBrowser doesn't work because it opens a
new window of the running Internet Explorer, but if I start a new IE
process (with System.Diagnostics.etc..) I don't know how to use it "as
a browser" from my code.

I suppose I should just start a new IE process and then connect to it
using some kind of magic, but:
a. how can I find the IE *I* just started, in a reliable way? I am not
sure that checking for its URL is reliable enough... is there some
sort of process ID to look for?
b. when I find it, how do I "cast" it to my desired object?

As you can see I am really a newbie Windows programmer... (I come from
a Unix background)

Thanks,
Federico

Perhaps it would be best if you told us what you are trying to
accomplish so that we could help. If you are trying to control the
webbrowser it is most likely that you want to host a web browser in your
app.

LS
 
F

Federico Cozzi

Perhaps it would be best if you told us what you are trying to
accomplish so that we could help.  If you are trying to control the
webbrowser it is most likely that you want to host a web browser in your
app.

Simply put: I want to start and control the webbrowser in my app, but
I want it NOT to share the same process of any external IE process
already running.

What happens now:
a. I open an IE, say at www.google.com
b. I run my program, which creates a webbrowser
c. Task manger tells me that this is a new window of the already
running IE, not a new IE process.

Basically, I would like to create a new webbrowser with the parameter
"create a new process, don't reuse existing process" but I can't find
such parameter.

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top