您的位置:首页 > 其它

在当前路径创建一个报告文件

2013-02-26 19:34 225 查看
void CABCToolDlg::CreateReportFile(CHAR cDiskLable)

{

CTime time = CTime::GetCurrentTime();

m_csReportFileName = GetCurrPath();

m_csReportFileName += "\\ABCTestReport\\";

if (!::PathFileExists(m_csReportFileName))

{

CreateDirectory(m_csReportFileName, NULL);

}

m_csReportFileName += cDiskLable;

m_csReportFileName += time.Format("%y%m%d%H%M%S");

m_csReportFileName += ".txt";

CStdioFile file;

if (file.Open(m_csReportFileName, CFile::modeCreate))

{

file.Close();

}

}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐