Link to home
Start Free TrialLog in
Avatar of MarcGraff
MarcGraffFlag for United States of America

asked on

Open URL in VB.NET

How would one open a URL in VB.NET

example:
IExplorer.Open("http://www.google.com")

   - Marc
ASKER CERTIFIED SOLUTION
Avatar of Mikal613
Mikal613
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
System.Diagnostics.Process.Start("http://www.google.com")
Avatar of seeflat
seeflat

Imports System.Diagnostics

-------------------------------------------------------------------------

Dim procOptions = New ProcessStartInfo("C:\Program Files\Internet Explorer\iexplore.exe", "http:\\www.google.com")
procOptions.UseShellExecute = False  ' set to true to make silent/background
Dim myProcess = Process.Start(procOptions)

HTH
Avatar of MarcGraff

ASKER

Thank you!

   - Marc
Whoops! Didn't refresh; however while Mikal613's solution will work; you don't have a reference to the process.
With the way I do it, you can issue: myProcess.CloseMainWindow() and the window will close, among other possibilities.

I just don't like fire and forget stuff.