file

I need a way to change the file modified date in VB6 even if no changes happen to the file Myfile.txt
abidsmlAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Erick37Commented:
"Obtaining and Changing a File's Created, Accessed and Modified Dates"

http://www.mvps.org/vbnet/code/fileapi/filedatetime.htm
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
planaskCommented:
Or try a less engineering way.
If it is really a .TXT file try adding a single space at the end and save it. Open it again, eat the space you've just added and save it again.
0
mark2150Commented:
I think if you just open the file for append and then close it the date will be changed even if no data is added.

FileID = Freefile
OPEN "Myfile" for append as #FileID
Close #FileID

M
0
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

sml41Commented:
mark, when i do that and check the file properties, the modified date is still the same ??
0
mark2150Commented:
Then use planask's idea. I didn't test it, but depending on the OS the date can change. A file on a Novell server will show an update.

M
0
abidsmlAuthor Commented:
Erick37
the programme you suggested is too complicated to follow but i learned things from it and solved my problem.


thanks all.  
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic Classic

From novice to tech pro — start learning today.