Differences between 6.1 5.73

Everything else that doesn't fall into one of the other PB categories.
kinglestat
Enthusiast
Enthusiast
Posts: 746
Joined: Fri Jul 14, 2006 8:53 pm
Location: Malta
Contact:

Re: Differences between 6.1 5.73

Post by kinglestat »

@jackalad

.i has a different size in 32bit and 64bit
Since this is a compiler I needed structures which would remain the same size
I may not help with your coding
Just ask about mental issues!

http://www.lulu.com/spotlight/kingwolf
http://www.sen3.net
juergenkulow
Enthusiast
Enthusiast
Posts: 581
Joined: Wed Sep 25, 2019 10:18 am

Re: Differences between 6.1 5.73

Post by juergenkulow »

boddhi wrote: Thu May 02, 2024 5:22 pm by boddhi » Thu May 02, 2024 5:22 pm
And some PB functions, like Date(), didn't need .i, only .l, until PB 6.10 regardless 32 or 64-bit OS.
I think that many codes using these functions should no longer work for this reason too.

Code: Select all

; Check all Programs with Date() and similar for replacement .l by .q
newyear2039.l=Date(2039,1,1,0,0,0)
Debug FormatDate("%yyyy %mm %dd %hh %mm",newyear2039)
; 1902 11 25 17 11
boddhi
Enthusiast
Enthusiast
Posts: 524
Joined: Mon Nov 15, 2010 9:53 pm

Re: Differences between 6.1 5.73

Post by boddhi »

juergenkulow wrote: ; Check all Programs with Date() and similar for replacement .l by .q
newyear2039.l=Date(2039,1,1,0,0,0)
Debug FormatDate("%yyyy %mm %dd %hh %mm",newyear2039)
; 1902 11 25 17 11
but :

Code: Select all

Date1.l=Date(1601,1,1,1,1,1)
Date2.q=Date(1601,1,1,1,1,1)
Debug FormatDate("%yyyy/%mm/%dd %hh:%mm:%ss",Date1) ; => 2009/04/22 20:04:49
Debug FormatDate("%yyyy/%mm/%dd %hh:%mm:%ss",Date2) ; => 1601/01/01 01:01:01
If my English syntax and lexicon are incorrect, please bear with Google translate and DeepL. They rarely agree with each other!
Except on this sentence...
juergenkulow
Enthusiast
Enthusiast
Posts: 581
Joined: Wed Sep 25, 2019 10:18 am

Re: Differences between 6.1 5.73

Post by juergenkulow »

Yes exactly:

Code: Select all

;Value range of Date()
Debug FormatNumber(Date(1601,1,1,0,0,0),0)
Debug FormatNumber(Date(9999,12,31,23,59,59),0)
Debug Hex(Date(1601,1,1,0,0,0),#PB_Quad)
Debug Hex(Date(9999,12,31,23,59,59),#PB_Quad)
; -11,644,473,600
; 253,402,300,799
; FFFFFFFD49EF6F00
; 3AFFF4417F
Sergey
User
User
Posts: 53
Joined: Wed Jan 12, 2022 2:41 pm

Re: Differences between 6.1 5.73

Post by Sergey »

juergenkulow wrote: Sat May 04, 2024 8:51 am Debug FormatDate("%yyyy %mm %dd %hh %mm",newyear2039)
For minutes use %ii :wink:
Post Reply