Open Browser to Windows Explorer

Technology specific object identification, supported applications, web technologies, and 3rd party controls.
Posts: 48
Joined: Tue Aug 14, 2012 5:47 pm

Open Browser to Windows Explorer

Post by regex » Tue Oct 23, 2012 6:43 pm

I am trying to open a browser to a particular path:

Host.Local.OpenBrowser(pathVar, "IE", "", false, false);

This does not allow for a string varibale to be used as the startup location.

I also tried system.diagnostic.process.start("expoloer.exe", path);

But for some reason it doesn't open to the correct path during test runs.

Any suggestions on how to use a variable in place of the URL for:

Host.local.openBrowser("http://www.", "IE", "", false, false):

User avatar
Posts: 1336
Joined: Thu Oct 16, 2008 6:46 pm
Location: Arizona, USA

Re: Open Browser to Windows Explorer

Post by Ciege » Tue Oct 23, 2012 10:00 pm

This works for me...

Code: Select all

ProcessStartInfo startInfo = new ProcessStartInfo("iexplore.exe");
startInfo.WindowStyle = ProcessWindowStyle.Maximized;
startInfo.Arguments = URL;
If this or any response has helped you, please reply to the thread stating that it worked so other people with a similar issue will know how you fixed your issue!


User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA

Re: Open Browser to Windows Explorer

Post by Support Team » Wed Oct 24, 2012 10:00 am


@Ciege: Thank you for your solution!

In general, it should also work with the open browser function:
Host.Local.OpenBrowser(path, "IE", "", false, false);

I have used this function with a path variable to open a specific page.
What is the value of your path variable?
Did you get any error message by using this?

Which Ranorex version are you using?

Markus (T)
Ranorex Support Team