Comfirmed. Save and then hit F5 works fine. No save = crash. Empty or not empty makes no difference.
6.30 works fine. Only 6.40 Alpha en Beta1 has this problem on my side.
https://freeimage.host/i/qqJosZ7
Search found 19 matches
- Sat Feb 28, 2026 12:16 pm
- Forum: Bugs - IDE
- Topic: IDE 640 crash at compilation
- Replies: 6
- Views: 244
- Sun Jul 14, 2024 12:40 pm
- Forum: Coding Questions
- Topic: SOLVED - Why doesn't this work (round a float via a procedure) ???
- Replies: 6
- Views: 1044
Re: Why doesn't this work (round a float via a procedure) ???
Ok, thanks for the explanations, everybody. Looks like I picked up a bad habit along the way.
In this case it kind of sucks, since I'm working on a RayLib program, and RayLib uses floats everywhere.
It's only 40K lines to check. Search If....... I need a drink....

In this case it kind of sucks, since I'm working on a RayLib program, and RayLib uses floats everywhere.
It's only 40K lines to check. Search If....... I need a drink....
- Sun Jul 14, 2024 11:03 am
- Forum: Coding Questions
- Topic: SOLVED - Why doesn't this work (round a float via a procedure) ???
- Replies: 6
- Views: 1044
Re: Why doesn't this work (round a float via a procedure) ???
A float is not an expression.
You can do it like this:
If Int(Bounds\x) And Int(Bounds\y)
Or like this (better solution)
If Bounds\x <> 0 And Bounds\y <> 0
I know that <> #Null works fine. But If with a zero number should always return False. I'm using that all the time, never fails. And ...
- Sun Jul 14, 2024 10:36 am
- Forum: Coding Questions
- Topic: SOLVED - Why doesn't this work (round a float via a procedure) ???
- Replies: 6
- Views: 1044
SOLVED - Why doesn't this work (round a float via a procedure) ???
Hi,
I do not understand why the following code returns #True, since it should be #False.
Not using the procedure and using a manual Round function works fine.
But this should work imho...
Hmm, Asm compiler (x86 and x64) returns #True, but C compiler (x86 and x64) returns #False). Strange ...
I do not understand why the following code returns #True, since it should be #False.
Not using the procedure and using a manual Round function works fine.
But this should work imho...
Hmm, Asm compiler (x86 and x64) returns #True, but C compiler (x86 and x64) returns #False). Strange ...
- Fri Jan 22, 2021 8:30 am
- Forum: Tricks 'n' Tips
- Topic: Buddy Windows
- Replies: 12
- Views: 7643
Re: Buddy Windows
Better late then never, I guess :oops: :oops:
I made a small modification to the code, so the windows will also snap when they are moved within the grab zone.
Thanks for the initial code. :!:
; Buddy Windows by netmaestro (https://www.purebasic.fr/english/viewtopic.php?f=12&t=30316&hilit=Buddy ...
I made a small modification to the code, so the windows will also snap when they are moved within the grab zone.
Thanks for the initial code. :!:
; Buddy Windows by netmaestro (https://www.purebasic.fr/english/viewtopic.php?f=12&t=30316&hilit=Buddy ...
- Fri Oct 30, 2020 9:28 am
- Forum: Coding Questions
- Topic: Mod function returning the same value as the Divisor
- Replies: 7
- Views: 1972
Re: Mod function returning the same value as the Divisor
Or you use mpdecimal library https://www.bytereef.org/mpdecimal/Tawbie wrote:Hi Norm,
The issue with floats here is not the range that they support but the precision with which a float can represent a decimal number, before rounding occurs.
- Thu Aug 20, 2020 12:06 pm
- Forum: Tricks 'n' Tips
- Topic: Module System (PB-Internals)
- Replies: 18
- Views: 15448
Re: Module System (PB-Internals)
If 0 doesn't get executed. What is this supposed todo ?mk-soft wrote:Here is a cleaned module with system functions which is needed from time to time
Code: Select all
; Force Import Fonts If 0 : LoadFont(0, "", 9) : EndIf
- Sat May 09, 2020 8:22 am
- Forum: Coding Questions
- Topic: CompilerIf doesn't do short-circuit ?
- Replies: 7
- Views: 2159
Re: CompilerIf doesn't do short-circuit ?
@JagV12: I thought I tested this a while ago, but v5.62 also doesn't do it. Looks like it never worked that way. I allways try to use one line If's. Cleaner code.
@Fred: Thanks for the explanation.
@Fred: Thanks for the explanation.
- Fri May 08, 2020 12:31 pm
- Forum: Coding Questions
- Topic: CompilerIf doesn't do short-circuit ?
- Replies: 7
- Views: 2159
Re: CompilerIf doesn't do short-circuit ?
A semicolon in PureBasic is used to denote a comment. You don't need them in front of constants. Remove it and it'll work.
Of course it works without the semicolon. The whole point is to check if a constant exists (part 1). If it doesn't exist the second part should not be checked.
That is what ...
Of course it works without the semicolon. The whole point is to check if a constant exists (part 1). If it doesn't exist the second part should not be checked.
That is what ...
- Fri May 08, 2020 10:53 am
- Forum: Coding Questions
- Topic: CompilerIf doesn't do short-circuit ?
- Replies: 7
- Views: 2159
CompilerIf doesn't do short-circuit ?
PB does support short-circuit ( https://en.wikipedia.org/wiki/Short-circuit_evaluation ). Very helpfull.
The following code in 5.71 and 5.72 does not work (constant not found: #Test):
;#Test = #True
CompilerIf Defined(Test, #PB_Constant) And #Test
Debug "Hi there"
CompilerEndIf
Is there a ...
The following code in 5.71 and 5.72 does not work (constant not found: #Test):
;#Test = #True
CompilerIf Defined(Test, #PB_Constant) And #Test
Debug "Hi there"
CompilerEndIf
Is there a ...
- Sun Jun 02, 2019 2:49 pm
- Forum: Coding Questions
- Topic: FindData from Wilbert and Purifier ?
- Replies: 0
- Views: 1133
FindData from Wilbert and Purifier ?
Hi,
I use FindData from Wilbert ( http://forums.purebasic.com/english/viewtopic.php?f=12&t=62519 , the July 24 2018 version.
I understand that FindData uses just about every cpu register available, so I use DisableDebugger before and EnableDebugger afterward. Works fine.
Because I use FastString ...
I use FindData from Wilbert ( http://forums.purebasic.com/english/viewtopic.php?f=12&t=62519 , the July 24 2018 version.
I understand that FindData uses just about every cpu register available, so I use DisableDebugger before and EnableDebugger afterward. Works fine.
Because I use FastString ...
- Thu Mar 22, 2018 3:33 pm
- Forum: Coding Questions
- Topic: Disable TreeGadget Item
- Replies: 15
- Views: 4060
Re: Disable TreeGadget Item
Ok. Thanks for explaining that. Thanks to all who helped.
- Thu Mar 22, 2018 10:54 am
- Forum: Coding Questions
- Topic: Disable TreeGadget Item
- Replies: 15
- Views: 4060
Re: Disable TreeGadget Item
Structure StructNMTVITEMCHANGE Align #PB_Structure_AlignC
hdr.NMHDR
uChanged.l
hItem.i
uStateNew.l
uStateOld.l
lParam.i
EndStructure
Structure Struct2NMTVITEMCHANGE
hdr.NMHDR
uChanged.l
PB_Alignment.b[4]
hItem.i
uStateNew.l
uStateOld.l
lParam.i
EndStructure
Debug "With ALignC"
Debug ...
hdr.NMHDR
uChanged.l
hItem.i
uStateNew.l
uStateOld.l
lParam.i
EndStructure
Structure Struct2NMTVITEMCHANGE
hdr.NMHDR
uChanged.l
PB_Alignment.b[4]
hItem.i
uStateNew.l
uStateOld.l
lParam.i
EndStructure
Debug "With ALignC"
Debug ...
- Thu Mar 22, 2018 9:00 am
- Forum: Coding Questions
- Topic: Disable TreeGadget Item
- Replies: 15
- Views: 4060
Re: Disable TreeGadget Item
Nothing is changed from .i to .l.
This works fine
Structure StructNMTVITEMCHANGE Align #PB_Structure_AlignC
hdr.NMHDR
uChanged.l
hItem.i
uStateNew.l
uStateOld.l
lParam.i
EndStructure
This does not work:
Structure StructNMTVITEMCHANGE; Align #PB_Structure_AlignC
hdr.NMHDR
uChanged.l ...
This works fine
Structure StructNMTVITEMCHANGE Align #PB_Structure_AlignC
hdr.NMHDR
uChanged.l
hItem.i
uStateNew.l
uStateOld.l
lParam.i
EndStructure
This does not work:
Structure StructNMTVITEMCHANGE; Align #PB_Structure_AlignC
hdr.NMHDR
uChanged.l ...
- Wed Mar 21, 2018 1:03 pm
- Forum: Coding Questions
- Topic: Disable TreeGadget Item
- Replies: 15
- Views: 4060
Re: Disable TreeGadget Item
Yes, I found the pb event way. Works very well. I like the api way better, for my project anyway.
You can disable a item, but the user can still interact. It is only gray. This one does work:
EnableExplicit
Enumeration
#Window
#Tree
#Image1
#Image2
EndEnumeration
; These ones are not present ...
You can disable a item, but the user can still interact. It is only gray. This one does work:
EnableExplicit
Enumeration
#Window
#Tree
#Image1
#Image2
EndEnumeration
; These ones are not present ...