If its related directly to windows programming
then this could make your life easier :
Code:
#include <windows.h>
using namespace std;
int main()
{
HANDLE hFind;
WIN32_FIND_DATA FindData;
char line1[255] = "SomeDirectory\\Somefile.someextention";
/*
after specifying you directory, to do all the text files in the dir
use the file name *.txt, to do all the files use *.*
Ex. "c:\\windows\\*.exe" will read all of the exe files
in the windows folder.
Ex. "c:\\windows\\*.*" will read every file in the windows
directory.
*/
hFind = FindFirstFile(line1, &FindData); //Find first file
while (FindNextFile(hFind, &FindData)) //Find Next File
{
/*
Do something here
Ex. using cout << FindData.ftCreationTime << endl;
will display the creation time of the current file.
*/
}
FindClose(hFind);
/* //Options specifically for what your asking for.
FindData.ftCreationTime
FindData.ftLastAccessTime
FindData.ftLastWriteTime
*/
return 0;
}
If you have any questions fee lfree to pm me, i put this together
real quick so might have made some errors.