Search found 3721 matches

by Little John
Thu Apr 11, 2024 6:26 am
Forum: Coding Questions
Topic: PB 6.10 x64 OpenLibrary
Replies: 6
Views: 378

Re: PB 6.10 x64 OpenLibrary

jacdelad wrote: Thu Apr 11, 2024 4:47 am That's why the help clearly states to use .i for handles.
... and that's been the case for at least as long as I've been using PureBasic (15+ years).

PS: Please don't post your coding questions in the “Bug reports” section of the forum!
by Little John
Mon Apr 01, 2024 12:03 pm
Forum: Tricks 'n' Tips
Topic: Revised Chr() & Asc() for UTF-16 surrogate pairs
Replies: 19
Views: 5240

Re: Revised Chr() & Asc() for UTF-16 surrogate pairs

Oh, yes. I had forgotten that PeekS() requires the number of characters rather than the number of bytes. Thanks!
by Little John
Sun Mar 31, 2024 8:53 pm
Forum: Tricks 'n' Tips
Topic: Revised Chr() & Asc() for UTF-16 surrogate pairs
Replies: 19
Views: 5240

Re: Revised Chr() & Asc() for UTF-16 surrogate pairs

STARGÅTE, you saved my program.
Thank you very much!
by Little John
Sun Mar 31, 2024 5:57 pm
Forum: Coding Questions
Topic: Strange characters in shared code
Replies: 11
Views: 357

Re: Strange characters in shared code

BarryG wrote: Thu Mar 14, 2024 7:36 am Kind of makes sharing code by email 100% useless, don't you think?
Sharing code in the body of an e-mail actually is not a good idea.
Better attach your .pb file(s) to the mail.
by Little John
Sun Mar 31, 2024 5:36 pm
Forum: Tricks 'n' Tips
Topic: Revised Chr() & Asc() for UTF-16 surrogate pairs
Replies: 19
Views: 5240

Re: Revised Chr() & Asc() for UTF-16 surrogate pairs

The code in the first post here works fine e.g. with PB 5.73 LTS. Many thanks again to Demivec! However, when trying to run the code e.g. with PB 6.04 (x64) or PB 6.10 (x64) on Windows, an error is raised. I didn't test with other PB versions, though. The following snippet Procedure.s _Chr(v.i) ;ret...
by Little John
Sun Mar 31, 2024 12:22 pm
Forum: Coding Questions
Topic: Find a string in *Memory
Replies: 42
Views: 1273

Re: Find a string in *Memory

I see.
by Little John
Sun Mar 31, 2024 9:34 am
Forum: Bugs - Windows
Topic: ResizeWindow not working with DPI aware
Replies: 12
Views: 492

Re: ResizeWindow not working with DPI aware

Can someone with a 4k high DPI monitor check this out and confirm? If I run the following code the Window starts at position 0,0 and when I press the button to move the window to 0,0 using ResizeWindow, the Window ends up at -6,0 if DPI aware is enabled on a 4K monitor with scaling set to 175% It's...
by Little John
Wed Mar 06, 2024 11:49 am
Forum: Coding Questions
Topic: Word wrapping
Replies: 1
Views: 154

Re: Word wrapping

These are my word wrap functions.
by Little John
Sun Mar 03, 2024 11:35 am
Forum: Tricks 'n' Tips
Topic: DateEx: Extended Date library
Replies: 33
Views: 4462

Re: DateEx: Extended Date library

New version 2.01, 2024-03-03

Changed
  • Fixed bugs
  • Renamed procedure TimeZoneOffset() to TimeZone()
  • New public procedure TimeZoneStr()
  • New public procedure BlackFriday()
by Little John
Fri Mar 01, 2024 8:43 pm
Forum: Coding Questions
Topic: Solve 1 Equation with 2 Unknowns
Replies: 23
Views: 760

Re: Solve 1 Equation with 2 Unknowns

DarkDragon wrote: Fri Mar 01, 2024 8:17 pm It's still infinitely many, even if not at X = 0.
Yep, exactly!
by Little John
Fri Mar 01, 2024 3:01 pm
Forum: Coding Questions
Topic: HTML characters convert {Resolved]
Replies: 6
Views: 304

Re: HTML characters convert

Kwai chang caine wrote: Fri Mar 01, 2024 12:32 pm
U+0153 œ c5 93 LATIN SMALL LIGATURE OE
U+153 is a hexadezimal value => Chr($153) in PureBasic.
by Little John
Fri Mar 01, 2024 8:46 am
Forum: Coding Questions
Topic: Solve 1 Equation with 2 Unknowns
Replies: 23
Views: 760

Re: Solve 1 Equation with 2 Unknowns

X = (653184000 / (499 * Y)) 1) This equation also can be written like this: Y = 653184000 / (X * 499)   2) For a long time X was unknown, so that people all over the world had to calculate its value over and over again. Fortunately, about 10 years ago the world-renowned Max Planck Institute for Mat...
by Little John
Fri Feb 09, 2024 6:00 pm
Forum: Coding Questions
Topic: NaN() and if compare problem
Replies: 3
Views: 215

Re: NaN() and if compare problem

; ASM OK, C-Backend Bug? Number = Sqr(-1) If Number = NaN() [...] Wrong code. In order to check for NaN, only use PB's IsNaN() function. NaN is a special value. Testing for it should not be done using normal comparisons because there are actually many different values for NaN and whether or not NaN...