我想编个程序,能够读取CHM文件!

来源:百度知道 编辑:UC知道 时间:2024/05/17 20:31:53
不用功能很强大,能读去CHM文件就行了!!!
能不能给出一些代码?

这个可以借鉴一下:

http://www.vckbase.com/document/viewdoc/?id=1751

///////////////////////////////////
// 下面是两个回调函数的声明
BOOL CALLBACK FunLog(char* pstr);
BOOL CALLBACK FunProc(char* pstr);
//
// CompileHHP
// 调用HHA_CompileHHP编译chm工程
// 参数:pzFileName为待编译hhp文件名
// 作者:吴会然(wuhran@126.com)
// blog: http://blog.sina.com.cn/u/1272907062
////////////////////////////////////////////////////////////////////////////////////
void CCompileCHMDemoDlg::BuildChmFile(CString strHHPFile)
{
HINSTANCE hinstLib;
typedef BOOL (WINAPI *MYFUNC)(const char*, LPVOID, LPVOID, int);
BOOL fFreeResult, fRunTimeLinkSuccess = FALSE;
MYFUNC ProcAdd = NULL;

// Get a handle to the DLL module.
hinstLib = LoadLi