QT调用CHM方法

QDesktopServices desktopServices;
QString strUrl=QCoreApplication::applicationDirPath () ;
strUrl=QString("file:///%1/mainhelp.chm").arg (strUrl);
QUrl qqq(strUrl);
desktopServices.openUrl(qqq);

//打包的话就直接用这个路径

编译环境那个下的话需要将路径修改为当前路径,或者直接将CHM文件存在release或debug下

原文地址:https://www.cnblogs.com/seer/p/4718026.html