If you search the files section here, there should be a couple examples of numeric textbox classes.
PF
>If you have an input mask in a textbox to accept a decimal (say '999.99') and you just click on the box and enter, the results are strange. For example, you type 45 and you get 450.00 because the cursor was to the left of the box. If the is entered into via the tab order, then the whole thing is selected and all is well.
>
>I have told my user to be sure to select the whole box before entering, but I was wondering if there is another way to handle this.
>
>Thanks
(On an infant's shirt): Already smarter than Bush