Page 3 of 3

Re: Some date functions supporting also dates prior to 1970

Posted: Sun May 21, 2023 10:02 am
by BarryG
Thanks, I'll check it out again. There was a post by you there that said it was obsolete, so I ignored it before. Is that no longer the case?

Re: Some date functions supporting also dates prior to 1970

Posted: Sun May 21, 2023 10:20 am
by mk-soft
With the introduction of C-Backend, probably no more.
Remember that the date values are in UTC. This is important for logging, databases and sorting. That's why I decided to use UTC. Double because of the milliseconds. The decimal places are the milliseconds and the pre-decimal places are the seconds since 1970.

Re: Some date functions supporting also dates prior to 1970

Posted: Sat Nov 11, 2023 6:47 pm
by Andre
BarryG wrote: Sun May 21, 2023 2:40 am This Date module is great, but it doesn't compile with the C backend because it uses ASM. Is there an alternative Date module that doesn't use ASM so I can compile my app with the C backend? Thanks!
I just stumbled across the same problem. Because of the used ASM in this module I can't compile my whole project with the C-backend.... :?
There is no easy way to have it adapted for use with this backend (using CompilerIf variants of the current code for ASM, and a C-backend compatible version of the Date64() and Date64Info() procedures currently made with ASM code)?

(And I admit that I saw the newer module from mk-soft, but due to my very limited time I wasn't able to delve deeper into it and the necessary reprogramming of my project.... :oops:)

Re: Some date functions supporting also dates prior to 1970

Posted: Sat Nov 11, 2023 7:36 pm
by Little John
@André

DateEx:
  • runs with ASM and C backend
  • works fine on Windows and Linux
  • on Mac OS, functions for current local time and UTC are missing

Re: Some date functions supporting also dates prior to 1970

Posted: Sat Nov 11, 2023 7:44 pm
by mk-soft

Re: Some date functions supporting also dates prior to 1970

Posted: Sat Nov 11, 2023 8:03 pm
by the.weavster
Don't overlook the fact SQLite's date functions are available to you :wink:

Re: Some date functions supporting also dates prior to 1970

Posted: Sun Nov 12, 2023 6:20 pm
by Andre
Thanks LittleJohn and mk-soft for your modules, I have both stored for later usage :-)

Because of my needs (switching between data values and strings, get/set the date in a CalenderGadget, be compatible with Windows and MacOS) I've now used the DateTime module (mk-soft) and could easily switch from the functions of the Date64 module (this topic) to the new one. Thank you :D