1.

Solve : Displaying the file creation date?

Answer»

Quote from: BC_Programmer on May 05, 2009, 02:05:18 PM

does DOS even maintain both the modified AND created dates? I'm not sure I remember correctly.

There is no created date in MS-DOS 6.22. Version 7.10 and later can store CREATION/modified but only when LFNs are enabled.





Quote from: gh0std0g74 on May 04, 2009, 06:15:18 PM
because of reasons like what you have posted? requirement changes? in the past you don't need to find out about creation date, but now you do, and then you found out that DOS6.22 doesn't have the facility to allow that? worse, you went to search for a third party tool and found it does the work you want, but is not written to be run on DOS6.22 because its too old? are these valid reasons for you?
Wow, steady.. Do you have ANGER issues with MS-DOS? I looked for a third party tool, did I? I was not aware that I'd done that. Have you tried my QBasic SOLUTION?
Hi Dias,

Thanks for the query, could I trouble you for a few pointers on dissecting the text file (I can DIRECT it to the file ok, but to get chunks back may involve a bit of heartache)

Thanks for taking the time to respond, I appreciate the 'help each other out' attitude some people have. I'm not sure if there's any way I can help you out..

All the best,Sorry Dias, just seen your Qbasic solution, I'll give it a try, eternal thanks.Quote from: AlexTheGrater on May 07, 2009, 10:11:27 AM
just seen your Qbasic solution

Code: [Select]REM Open the file previously created
REM Which has the output of DIR
open "dirline.txt" for input as #1

REM skip over the first 5 lines of the DIR output
for j=1 to 5: line input #1, d$:next j

REM Get the next line
line input #1, a$

REM I omitted this, it is probably good housekeeping
REM to close the file
close #1

REM Show the part of the line with the date / time info
REM that is, the 10 characters starting at position 29
print "File created on "; MID$(a$, 29, 10)

REM exit back to batch file
system
Thanks, Diaz. It works! You're a star..


Discussion

No Comment Found