setting timestamp from microsoft visual c?

A

AtPCLogic

Hi,
I'm not usually programming in C, so I'm lost and need a little help.
I need to copy a file from one directory to another and preserve the timestamp.
The OS is Windows 32 bit, including XP, 2000, NT and so on. Is there a way to
set the timestamp on the file for these environments? I know it could be done
in DOS using interrupt calls, but I don't think that can be done in the newer
environments. Any suggestions?

Thanks a bunch!
Brad
 
M

Malcolm

AtPCLogic said:
Is there a way to set the timestamp on the file for these
environments?
Calling fopen() will cause the OS to use default behaviour, which is
probably to timestamp files with current time. C doesn't have any
timestamping functions, so you will have to trawl through your MVC++
documentation for "timestamp" to find the right platform-specific function.
Alternatively a Microsoft-speific group may be able to help.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,183
Messages
2,570,977
Members
47,556
Latest member
the lucky frog

Latest Threads

Top