VC 检测文件是否存在
bool IsExistFile(LPCSTR pszFileName )
{
WIN32_FIND_DATA FindFileData;
HANDLE hFind;
hFind = FindFirstFile(pszFileName , &FindFileData);
if (hFind == INVALID_HANDLE_VALUE)
return false;
else
{
FindClose(hFind);
return true;
}
return false;
}
发表回复