How can i obtain the creation date of any given file? I expect theres a library function somewhere.
Simple to say but cant find any reference to it in my books.
Thanks for any help peeps
How can i obtain the creation date of any given file? I expect theres a library function somewhere.
Simple to say but cant find any reference to it in my books.
Thanks for any help peeps
What OS / Compiler ?
When all else fails, read the instructions.
If you're posting code, use code tags: [code] /* insert code here */ [/code]
The standard doesnt define functions to do this.
If you want this info, then you need an API for your specific OS..
If you are looking at windows, go to MSDN and look at GetFileAttributesEx()
Hi,
Probably it's not what you're looking for, but it could be useful.
Under a GNU-compatible system, check out struct stat and the function stat. The struct contains many attributes, inlcuding but not limited to - last access and last mod. timestamps.
Also, there is a great func in Borland C++ Builder 6. This is called FileGetAttr. The struct which holds the desired info is TSearchRec. You'll need Windows to use this.
Hope this helps!
Good luck!
Best Regards,
Bill
Thanks for the replys
I'm using DOS versions 4.08, 5.09 & 5.10 and VC++ 1.52 compiler.
Thanks all,
ended up using the dos.h header,
and functions _dos_findfirst , _dos_findnext
if anyone else is interested