Launch URL With Default Browser

'Add 1 CommandButton to your form (named Command1),
'To launch URL with default browser press the button.

'Insert the following code to your form:

Private Sub Command1_Click()
'Replace http://www.yahoo.com with the URL you want to launch.
'You can replace 'vbHide' with following settings, according to in which state
'you want to open the browser :
'vbHide ; vbMaximizedFocus ; vbMinimizedFocus ;vbMinimizedNoFocus ;
'vbNormalFocus ; vbNormalNoFocus

RetVal = SHELL("Start.exe http://www.yahoo.com", vbHide)
End Sub

Go Back