本人做了一个帮助主题,CHM文件,请问各位高手怎么把这个帮助主题集成到MFC程序中?
解决方案 »
- 菜鸟求助:填充问题
- 用了CFileDialog的函数,此函数的返回值不能为CString型?奇怪
- 以前的关于全局变量的贴子,现开新贴,请大虾们继续支持。
- 初学VC得困惑
- 非学术问题,在线等111111111111给分!!!!!!!!!!
- 如何使用IsTextUnicode函数
- 以后还能使用VC6吗?VISTA 和WINDOWS7下还能用VC6 吗?有根本区别吗?C++大家现在都用什么?
- 为什么序列化失败呢?我觉得这段程序没问题啊?
- 请问 用opencv怎么可以检测到图中角膜区域的亮环中心线?找到圆心?
- 在执行ShellExecute()启动Outlook,能否自动粘上某个文件作为附件??(Winzip8.0就实现这个功能)
- 窗口分割显示的问题
- 为什么我的这个菜单它没有什么宽度?,救命,急,在线等
HWND HtmlHelp(
HWND hwndCaller,
LPCSTR pszFile,
UINT uCommand,
DWORD dwData) ;
Parameters
hwndCaller
Specifies the handle (hwnd) of the window calling HtmlHelp(). The help window is owned by this window.
When the help window is closed, HtmlHelp() will return focus to the owner unless the owner is the desktop. If hwndCaller is the desktop, then the operating system determines where focus is returned. In addition, if HtmlHelp() sends any notification messages from the help window, they are sent to hwndCaller as long as you have enabled notification message tracking in the help window definition. pszFile
Depending on the uCommand value, specifies the file path to either a compiled help (.chm) file, or a topic file within a specified help file.
A window type name can also be specified, preceded with a greater-than (>) character. If the specified command does not require a file, this value may be NULL. uCommand
Specifies the command to complete.
dwData
Specifies any data that may be required, based on the value of the uCommand parameter.
Return Value
Depending on the specified uCommand and the result, HtmlHelp() returns one or both of the following: The handle (hwnd) of the help window.
NULL. In some cases, NULL indicates failure; in other cases, NULL indicates that the help window has not yet been created.
Example
The following example calls the HH_DISPLAY_TOPIC command to open the help file named Help.chm and display its default topic in the help window named Mainwin. Generally, the help window specified in this command is a standard HTML Help Viewer. HWND hwnd =
HtmlHelp(
GetDesktopWindow(),
"c:\\Help.chm::/Intro.htm>Mainwin",
HH_DISPLAY_TOPIC,
NULL) ;
Note When using the HTML Help API, set the stack size of the hosting executable to at least 100k. If the defined stack size is too small, then the thread created to run HTML Help will also be created with this stack size, and failure could result. Optionally, you can remove /STACK from the link command line, and remove any STACK setting in the executable's DEF file (default stack size is 1MB in this case). You can also you can set the stack size using the /Fnumber compiler command (the compiler will pass this to the linker as /STACK).