mfc判断目录是否为空
时间:2021-06-19 18:41:36
收藏:0
阅读:0
BOOL IsFolderEmpty(string path)
{
string str = path + "\\*.*";
CFileFind ff;
BOOL bFound;
bFound = ff.FindFile(str.c_str());
while (bFound)
{
bFound = ff.FindNextFile();
if (!ff.IsDots())
{
return FALSE;
}
}
ff.Close();
return TRUE;
}
评论(0)