Search found 760 matches
- Tue Dec 16, 2025 8:57 pm
- Forum: Coding Questions
- Topic: SOLVED Inputting/Validating Form Data
- Replies: 20
- Views: 1229
Re: Inputting/Validating Form Data
Hi spikey.
I'm sort of confused. This code seems more comprehensive as it better refines the input - but isn't this the .pbf Form, and will it not be
automatically re-generated by the Form Designer ?
Thanks,
M...
My apologies, I didn't intend to confuse. Yes, I expanded the code as a self ...
- Tue Dec 16, 2025 7:32 pm
- Forum: Coding Questions
- Topic: SOLVED Inputting/Validating Form Data
- Replies: 20
- Views: 1229
Re: Inputting/Validating Form Data
The StringGadget has the '#PB_String_Numeric' property which will constrain the gadget to positive integers.
You can also set a maximum length on a string gadget via SetGadgetAttribute, this will stop too many characters being entered:
SetGadgetAttribute(CustName, #PB_String_MaximumLength, 4 ...
You can also set a maximum length on a string gadget via SetGadgetAttribute, this will stop too many characters being entered:
SetGadgetAttribute(CustName, #PB_String_MaximumLength, 4 ...
- Sat Dec 13, 2025 12:51 pm
- Forum: Coding Questions
- Topic: Update a seperate Logging window
- Replies: 5
- Views: 408
Re: Update a seperate Logging window
Are you using modules, and are WNDW_main and WNDW_log in different modules?captain_skank wrote: Fri Dec 12, 2025 12:51 pm The interesting pasrt for me was that i was creating and displaying the WNDW_log and showing the gadgetid in the editor gadget, but when i tried show it ( using debug ) in WNDW_main it was always returning an id of 0.
- Thu Dec 04, 2025 9:56 pm
- Forum: Bugs - Documentation
- Topic: FindString Mode Parameter
- Replies: 3
- Views: 676
Re: FindString Mode Parameter
Blast! I typo'd when I posted, despite trying very hard not to! The statement "case sensitive search (a=a) (default)" is not correct. In a case sensitive search A is not equal to a!
The correction I posted is correct, however. Compare with the French version - which is correct.
The correction I posted is correct, however. Compare with the French version - which is correct.
- Wed Dec 03, 2025 10:50 pm
- Forum: The PureBasic Form Designer
- Topic: Disabling "Generate event procedure" deletes event procedure in already existing form with event procedures?
- Replies: 4
- Views: 490
Re: Disabling "Generate event procedure" deletes event procedure in already existing form with event procedures?
Is the PureBasic Form Designer behaving correctly?
The form designer is behaving as it is programmed, yes. Is the behaviour you're describing desirable in a perfect solution, probably not.
Am I misunderstanding something?
Probably. The form designer doesn't maintain the code directly, it ...
- Wed Dec 03, 2025 8:27 pm
- Forum: Feature Requests and Wishlists
- Topic: Case insensitive CountString
- Replies: 2
- Views: 462
Re: Case insensitive CountString
Of course, but it's an optimisation that it would be nice to have available and makes the two commands consistent.
- Wed Dec 03, 2025 5:31 pm
- Forum: Bugs - Documentation
- Topic: FindString Mode Parameter
- Replies: 3
- Views: 676
FindString Mode Parameter
In the FindString article, the Mode parameter description contains a typo, in the English and German versions:
should say:
Code: Select all
#PB_String_CaseSensitive: case sensitive search (a=a) (default).Code: Select all
#PB_String_CaseSensitive: case sensitive search (A≠a) (default).- Wed Dec 03, 2025 5:25 pm
- Forum: Feature Requests and Wishlists
- Topic: Case insensitive CountString
- Replies: 2
- Views: 462
Case insensitive CountString
Could CountString get the same Mode parameter as FindString please?
I currently have to have two copies of a string around for counting, original case and lower case.Help wrote:#PB_String_CaseSensitive: case sensitive search (a=a) (default).
#PB_String_NoCase : case insensitive search (A=a).
- Wed Dec 03, 2025 4:15 pm
- Forum: Coding Questions
- Topic: Enable FTS in SQLite
- Replies: 2
- Views: 338
Re: Enable FTS in SQLite
What makes you think it isn't enabled? A quick look says to me that it is and I can't think of any obvious reasons why Fred would choose to omit it.
For me, on 6.30B4, "PRAGMA compile_options;" returns:-
For me, on 6.30B4, "PRAGMA compile_options;" returns:-
Code: Select all
[15:09:40] ENABLE_FTS3
[15:09:40] ENABLE_FTS3_PARENTHESIS
[15:09:40] ENABLE_FTS4
- Sat Nov 15, 2025 8:08 pm
- Forum: Assembly and C Programming in PureBasic
- Topic: Strange issue with loading Pointers of Structures
- Replies: 2
- Views: 1217
Re: Strange issue with loading Pointers of Structures
I'm know I'm not following you entirely here (I've an infection and brain functions are impaired!) but I can see some problems.
1) The macro DbgREG is bugged. Where does _dbgval_ come from?
2) LEA and MOV perform two completely separate functions. LEA moves addresses into registers. MOV moves values ...
1) The macro DbgREG is bugged. Where does _dbgval_ come from?
2) LEA and MOV perform two completely separate functions. LEA moves addresses into registers. MOV moves values ...
- Tue Nov 11, 2025 10:18 pm
- Forum: Coding Questions
- Topic: How to update UI gadgets inside a procedure
- Replies: 13
- Views: 1290
Re: How to update UI gadgets inside a procedure
Thank you for the example, that looks easy! (I didn't know that Delay allowed events to continue.)
It doesn't. What infratec is doing in this example is creating a thread which runs alongside the main program. It uses PostEvent to tell the main thread that a UI update is appropriate. The main ...
- Sun Nov 09, 2025 2:19 pm
- Forum: Coding Questions
- Topic: The problem of finding an interval and the closest points.
- Replies: 4
- Views: 673
Re: The problem of finding an interval and the closest points.
If you always have four time slots you don't need to muck about with a list. Each task can have a fixed sized array.
I would also store Unix epoch timestamps (i.e. Q values from the Date() function) of the next event time in the array. Then you can also take advantage of the AddDate() function too ...
I would also store Unix epoch timestamps (i.e. Q values from the Date() function) of the next event time in the array. Then you can also take advantage of the AddDate() function too ...
- Sat Nov 08, 2025 10:36 pm
- Forum: Coding Questions
- Topic: Turn off Canvas Events during a MessageRequester() is open
- Replies: 7
- Views: 834
Re: Turn off Canvas Events during a MessageRequester() is open
I wonder why the #PB_EventType_LeftButtonDown for example is blocked with Requester, but not the #PB_EventType_MouseMove
It's in use by the modal dialog, whereas the mouse position isn't especially significant and hasn't been overriden by a dialog specific function. It's an emergent behaviour of ...
- Sat Nov 08, 2025 3:54 pm
- Forum: Coding Questions
- Topic: The problem of finding an interval and the closest points.
- Replies: 4
- Views: 673
Re: The problem of finding an interval and the closest points.
Are we talking 1D, 2D or 3D points here? How many control points are there likely to be? 10's, 100's or 1000's
- Sat Oct 18, 2025 3:17 pm
- Forum: Coding Questions
- Topic: Howto execute a program
- Replies: 9
- Views: 1001
Re: Howto execute a program
Also why would the .pbf code work standalone ?
When you compile and run a form design on its own, the form designer constructs a minimal event loop and adds this to the file content before passing it to the compiler. It does this invisibly.
Your program is terminating without doing anything ...