Number formatting

  • Thread starter Thread starter rguti
  • Start date Start date
R

rguti

I have a web form. I would like to format a numeric field. For example if
they type in 3,400.33 to format the control to $ 3,400.33 while they're
typing, basically the same as in many windows programs. Is this possible?
thanks
 
I have a web form. I would like to format a numeric field. For example if
they type in 3,400.33 to format the control to $ 3,400.33 while they're
typing, basically the same as in many windows programs. Is this possible?
thanks

If you want to do it as they type, that's Javascript. Search around on
the web, you'd have to tie into the keypress event more than likely and
format it yourself. You could then wrap this up in your own custom server
control, which would automatically output the Javascript. Perhaps someone
else here has done it, or I'm sure there's some 3rd party controls out
there. Otherwise do a little Google'ing and I'm sure you'll find some
ideas quickly.
 
Back
Top