Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Trailing Zeros in Text Box
Message
From
02/05/2005 16:32:19
Michael Gass
Instructional Software, Inc.
Kirkland, Washington, United States
 
 
To
02/05/2005 11:13:03
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01010087
Message ID:
01010302
Views:
20
Thanks Hilmar - I wanted to be more flexible than what Input and Format allow. I'm thinking of using a form variable to tie the text box to so the data from the table can be modified prior to putting it into the form variable. Then the data in the text box wouldn't be tied to the number of decimals in the field. I was hoping for a simple process but this might be the best I can get. Thanks. - Mike


>>I have a numeric field in a table with 3 decimal places that’s the control source for a Txtnumeric text box from the Codemine cmGadget.vcx. I would like trailing zeroes in the table to not appear in the text box. I would also like the user to be able to enter up to three decimal places in the text box but when he leaves the text box any trailing zeros would disappear from the text box. I was hoping for something simple that I’m missing in the Txtnumeric text box or a simple function that would take care of the problem for me. Any suggestions would be appreciated. Thanks!
>
>I usually get rid of the spaces when reading the value out:
>
>
>lcUserOption = alltrim(ThisForm.TxtOption.Value)
>
>
>Even when the TextBox is not tied to a field (through the ControlSource), trailing blanks sometimes appear.
>
>When the TextBox is directly tied to a field, it will always have the size of the field. You can, however, control user input through properties such as .InputMask or .Format.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform