vb中,如何打开一个PDF文件,仅仅是打开!
想要实现,在界面上放置一个按钮,此按钮就是实现打开一个PDF文件,而界面不需要显示
PDF的任何内容,仅仅是想打开一PDF文件而已!
本人想了好久,没实现!希望各位给些指点吧!谢谢!
[解决办法]
Public 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(me.hwnd,"open","文件全路径","","",1)
[解决办法]
你的open后边多了空格。
[解决办法]
ShellExecute Me.hwnd, "open", app.path & "\传感器支架L400.pdf", vbNullString, vbNullString, 1