我用
App.HelpFile = App.Path + "\readme.chm"
菜单名.HelpContextID = 1 ' 注释:选定ID号为1的主题
SendKeys "{F1}" 的方法连接chm文件,运行时没有任何反映,请问这怎么办?
App.HelpFile = App.Path + "\readme.chm"
菜单名.HelpContextID = 1 ' 注释:选定ID号为1的主题
SendKeys "{F1}" 的方法连接chm文件,运行时没有任何反映,请问这怎么办?
输入“调用 chm 帮助的示例”搜索。
这是界面:http://www.mndsoft.com/softimg/UsingHtml.png
在主窗体中:
Private Sub Form_Load()
App.HelpFile = App.Path & "\help.chm"
End Sub
设置了一个帮助菜单cmdhelp
Private Sub Cmdhelp_Click() '界面上有一个帮助按钮
SendKeys "{F1}"
End Sub但运行程序时,点击此菜单无任何反映,点击f1也没反映,我该怎么改?
Shell "hh.exe app.path & \help.chm", vbNormalFocus 'help.chm为指定的帮助文件,可包含路径。
End Sub
VB声明
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
调用帮助文件
Call ShellExecute(hwnd, "Open", app.path & “\help.chm”, "", App.Path, 1)