Declare Function htmlhelp Lib "hhctrl.ocx" _ Alias    "HtmlHelpA" (ByVal hwnd As Long, _ ByVal lpHelpFile As String, ByVal wCommand _ 
As Long, ByVal dwData As Long) As Long 
在VB中使用语句如下:比方form名为form1:chm文件中有一张网页名为AAA.htm   
Dim m_Value As Long m_Value = htmlhelp(form1.hwnd, App.Path & "\帮助文件.chm::/AAA.htm",    0, 0) 
If m_Value = 0 Then MsgBOX "无法打开帮助文件!"
End If