Link to home
Start Free TrialLog in
Avatar of nealgs
nealgsFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Need to preserve a files last access and modified date/time using VB6

Hi all,

I need to be able to open word and excel docs from a VB6 app, but once finished with the docs, the last access and last modified dates/times need to be reset to what they were before they were opened by the application.

This used to be easy in DOS/Win16 days but everytime i attempt to retrieve a files last accessed date, the last accessed data is changed to the current time (as in the file has just been opened to retrieve the last accessed info, so the system updates the last accessed info on the file)

How on earth do you do it.  I'm using createfile etc without any luck.

The app will be used on 100's of word/excel docs so need to keep date/times.

ASKER CERTIFIED SOLUTION
Avatar of Computron
Computron

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Computron
Computron

Avatar of nealgs

ASKER

Hi Computron - thanks for the pointers, but already been there and tried them.

Didn't appear to work as last accessed date was still getting changed, but will try them again.

Gary
SOLUTION
Avatar of glass_cookie
glass_cookie

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial