vl-file-systime

vl-file-systime

john.uhden
Mentor Mentor
1,019 Views
3 Replies
Message 1 of 4

vl-file-systime

john.uhden
Mentor
Mentor

Can anyone explain why vl-file-systime returns seconds that are > 60, like 535 and 978?

 

For my purposes I don't think seconds really matter, so maybe I should just ignore them unless maybe they are supposed to be divided by 60 and added to the minutes.  Or maybe I should be using DOSLIB or that scripting thingy, but I don't want to bloat a freebie to one of our needy.  There's no need to teach them string theory when all they want to learn is F=ma.

John F. Uhden

0 Likes
Accepted solutions (1)
1,020 Views
3 Replies
Replies (3)
Message 2 of 4

john.uhden
Mentor
Mentor

If that isn't bad enough, it also returned 0 for the day of the week (Sunday), whereas it's supposed to return 1 for Monday, 2 for Tuesday, and 7 for Sunday.

 

I compensated by making my conversion list '("Sun" "Mon" "Tue"  .............  "Sun").  Just like The Beatles... "8 Days A Week"

 

I'll bet that Dale Fugier didn't write that function for Autodesk.  Oops, maybe it dates back to Peter Petrov, but I no longer have Vital Lisp installed

John F. Uhden

0 Likes
Message 3 of 4

dbroad
Mentor
Mentor
Accepted solution

There are definitely some documentation errors there.  Just shows that you shouldn't work on Sundays.  I think you can rely on Sunday being the 0th day of the week.  

 

The last argument (there are 8 in contrast to the documentation) is milliseconds.  You should also account for the possibility that the time as expressed by the operating system in the file explorer may and probably will be an hour off if the file was created while Daylight savings time was enabled.

Architect, Registered NC, VA, SC, & GA.
0 Likes
Message 4 of 4

john.uhden
Mentor
Mentor

That's comical.  It might be a day off or an hour off, but the inaccuracy is precise.

What's the difference; my wife says I'm oblivious anyway.  :]

John F. Uhden

0 Likes