PlanetSquires Forums

Support Forums => Other Software and Code => Topic started by: Robert Eaton on November 18, 2009, 11:32:04 PM

Title: How to Set text for a FireTextBox with a numeric mask enabled
Post by: Robert Eaton on November 18, 2009, 11:32:04 PM
The custom mask setting is a nice feature of the FireTextBox control.
However, since the set text command wants a string argument, the control ignores everything I send to it.

I've tried to turn off the mask by sending a %FIRETEXTBOX_NONE before sending the string, but that hasn't worked. (I'm probably doing this incorrectly  ::) )


Any advice?
Title: Re: How to Set text for a FireTextBox with a numeric mask enabled
Post by: Paul Squires on November 19, 2009, 11:04:20 AM
Hi Bob,

Something does seem to be wrong there.... I am testing this control now. I'll report back as soon as possible.
Title: Re: How to Set text for a FireTextBox with a numeric mask enabled
Post by: Robert Eaton on November 19, 2009, 11:15:00 AM
Paul,
I was finally able to turn off the numeric mask using a send message command, but when I turn it back on the value disappears again.
Title: Re: How to Set text for a FireTextBox with a numeric mask enabled
Post by: Paul Squires on November 19, 2009, 11:22:25 AM
This was a very subtle bug. You can fix it yourself by modifying the "FireTextBox.inc" file located in the Custom Control folder.

Make sure to close FF3 first.

Open "FireTextBox.inc".

Go down to line 1739 (ie. the line that says CASE %WM_SETTEXT) and add this code immediately after that line:

Function = CallWindowProc( OldProc, hWnd, wMsg, wParam, lParam )

Save the file.

Start up FF3 and try your code again. It should work. If it does not, then please let me know.

Title: Re: How to Set text for a FireTextBox with a numeric mask enabled
Post by: Robert Eaton on November 19, 2009, 12:26:35 PM
Yup, that did the trick!