Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hWnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As LongPrivate Sub Command1_Click() Dim a As Long a = ShellExecute(0, "open", "www.sohu.com", vbNull, vbNull, 0) End Sub
Private Sub Command1_Click() Shell "C:\Program Files\Internet Explorer\iexplore www.sohu.com" End Sub
还有一个就是 dim Iex as new intnetexplor iex.navigate "http://www.sohu.com"
Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" (ByVal hWnd As Long, ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As LongPrivate Sub Command1_Click() ShellExecute 0&, vbNullString, "http://www.121.com", vbNullString, vbNullString, vbNormalFocus
Dim a As Long
a = ShellExecute(0, "open", "www.sohu.com", vbNull, vbNull, 0)
End Sub
Shell "C:\Program Files\Internet Explorer\iexplore www.sohu.com"
End Sub
dim Iex as new intnetexplor
iex.navigate "http://www.sohu.com"
ShellExecute 0&, vbNullString, "http://www.121.com", vbNullString, vbNullString, vbNormalFocus