F freak Member Jan 6, 2009 #1 Is there any way to get the file dates with "input from os-dir"? What I'm trying to do is get the oldest file in a directory so it can be overwritten.
Is there any way to get the file dates with "input from os-dir"? What I'm trying to do is get the oldest file in a directory so it can be overwritten.
jongpau Member Jan 6, 2009 #2 You can definitely get it through the FILE-INFO system handle. Code: FILE-INFO:FILE-NAME = "<opsys file name>":U. MESSAGE FILE-INFO:FILE-CREATE-DATE FILE-INFO:FILE-MOD-DATE VIEW-AS ALERT-BOX. So I suppose you can read the directory contents with OS-DIR and then get the date for each file in the directory by using FILE-INFO. Hope this helps Paul
You can definitely get it through the FILE-INFO system handle. Code: FILE-INFO:FILE-NAME = "<opsys file name>":U. MESSAGE FILE-INFO:FILE-CREATE-DATE FILE-INFO:FILE-MOD-DATE VIEW-AS ALERT-BOX. So I suppose you can read the directory contents with OS-DIR and then get the date for each file in the directory by using FILE-INFO. Hope this helps Paul
S sdjensen Member Jan 7, 2009 #3 Create a temptable containing the filenames and the date. You cannot specify which order that you should receive the filenames from Os-dir as it is given by the operating system.
Create a temptable containing the filenames and the date. You cannot specify which order that you should receive the filenames from Os-dir as it is given by the operating system.