|
-
August 3rd, 1999, 09:15 AM
#4
Re: File list
CString csFilePattern = "C:\TEMP\*.*"; // use your mask here
WIN32_FIND_DATA findFileData;
HANDLE hFindFileInfo;
hFindFileInfo = FindFirstFile(csFilePattern, &findFileData);
if (hFindFileInfo != INVALID_HANDLE_VALUE)
{
do
{
CString csFile = findFileData.cFileName; // The full name of file with ext not including path
DeleteFile(csFile); // Do your file op here
} while (FindNextFile(hFindFileInfo, &findFileData));
FindClose(hFindFileInfo);
}
HTH,
Chris
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|