Describe how to use HTML Help (.chm) in Visual Basic 6.
Everyone knows whether the WinHelp help file can be called through the ActiveX control "Microsoft Common Dialog Control" in Visual Basic 6, then can I call the HTML Help file with the same method?
I am Sorry, the answer is negative.
But Visual Basic 6 itself supports HTML help, we can completely call HTML Help files directly without remained with any other ActiveX control or Windows API function.
You can set the HTML help file you need in the engineering property, or set the value of the member variable app.helpfile (= help_file_name) in the program to the user's help file name, such as the above case Application APP .Helpfile = "c: /learn/learn.chm" to set the desired help file - of course, using this absolute path I don't agree - you can change to app.helpfile = app.path "Learn. CHM. Then add a "Help" button on the form and add the following code to the button's click event (assuming the Name property of the button is "cmdhelp"):
PRIVATE SUB CMDHELP_CLICK () cmdhelp.helpContextId = 1 'Selected ID No. 1 Theme SendKeys "{F1}" End Sub
Of course, the HelpContextId attribute value of the button can be changed to other values depending on the actual situation. OK! Your program has added a beautiful and convenient HTML help, you can have a lot of color to your program! = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = -
//
__________ / lb / ___ Outinn
/ _ [] _ / ____ / /
/ _________ / | () | / __ /
Http://outinn.yeah.net/
| ____ / - | __ | - / | Welcome to Visit Outinn!
| __ | == | ___ | || | __ |
- = - = - = - | _ || _ | = - FANCY,
Outinn@china.com