Autorun needs to open HTML browser, How?

J

Joel Barsotti

So I know how to setup the autorun.ini to to execute a paticular file.

One solution is to use shellexecute, but say on my machine that opens up the
HTML document in visual studio.

So I need to create a small app to open IE with a paticular URL and it would
be helpfull if I could control the size, poistion and menus associated with
it.

Thanks for the help.
 
N

Nick Malik [Microsoft]

that will work, until you get to a machine that has firefox as the default
browser.

Why does Visual Studio open for html files on your machine? Doesn't do that
on any of my machines?

--
--- Nick Malik [Microsoft]
MCSD, CFPS, Certified Scrummaster
http://blogs.msdn.com/nickmalik

Disclaimer: Opinions expressed in this forum are my own, and not
representative of my employer.
I do not answer questions on behalf of my employer. I'm just a
programmer helping programmers.
 
C

Cor Ligthert

Joe,

I am not sure about your question however this is a way to start the default
browser.
There are more properties for the ProcessStartInfo so maybe you can look for
that for yourself when this is somehting you need.

\\\\
System.Diagnostics.Process p = new System.Diagnostics.Process();
System.Diagnostics.ProcessStartInfo pi =
new System.Diagnostics.ProcessStartInfo();
pi.FileName = "http://msdn.microsoft.com";
pi.UseShellExecute = true;
p.StartInfo = pi;
p.Start();
////

Cor

"Joel Barsotti"
 
J

Joel Barsotti

This is along the lines of what I want to do.

Is their anyway that I can control how the browser opens? I'm looking for
the same kind of control you'd get from using the javascript window.open()
command.
 

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