声明: 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 Long使用: ShellExecute 0,"Open","c:\abc.doc","","",vbNormalFocus
Shell "C:\Program Files\Microsoft Office\Office\WINWORD.EXE e:\test.doc", 1
:)祝你开心!
Shell "start test.txt", 1
Shell "start test.tif", 1
Shell "start test.html", 1
......
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 Long使用:
ShellExecute 0,"Open","c:\abc.doc","","",vbNormalFocus