QString strFolderPath = QCoreApplication::applicationDirPath()+"/filestorge/YTQ/";
QDir dir(strFolderPath);
if (!dir.exists())
return false;
gString filePath = strFolderPath +QString(“YTQ.docx”);
QFile file(filePath);
//文件存在,则删除;
if(file. exists())
{
QFile::remove(fi1ePath);
return true;
}