Problem: They want commas in numeric data in a textbox.
I am an experienced .NET programmer, and I make a lot of websites with financial calculations, text boxes, reports etc.
I have a particular page that has numerous textboxes for a person to type in numeric data; I validate the textboxes etc. when the data is submitted, etc.
Whenever I display such data outside of a textbox I always use formatnumber, formatcurrency, etc., depending on the type of data. If a person puts commas in the textbox, I strip them out with replace statement before I validate it.
HEre is my problem; a meddler in my company wants the textbox to always display commas like formatted statements do. So if I open the page, and textboxes are prepopulated with data, that data must use commas.
Well, that goes against all of the "best work practices" and standards that I have ever seen.
What do you people think? Have you ever done this? I want to completely ignore it and apply some technical rationale to it; we simply don't do data forms this way, etc.
Does anyone have any ideas about this?
Thank you
Nelson
I am an experienced .NET programmer, and I make a lot of websites with financial calculations, text boxes, reports etc.
I have a particular page that has numerous textboxes for a person to type in numeric data; I validate the textboxes etc. when the data is submitted, etc.
Whenever I display such data outside of a textbox I always use formatnumber, formatcurrency, etc., depending on the type of data. If a person puts commas in the textbox, I strip them out with replace statement before I validate it.
HEre is my problem; a meddler in my company wants the textbox to always display commas like formatted statements do. So if I open the page, and textboxes are prepopulated with data, that data must use commas.
Well, that goes against all of the "best work practices" and standards that I have ever seen.
What do you people think? Have you ever done this? I want to completely ignore it and apply some technical rationale to it; we simply don't do data forms this way, etc.
Does anyone have any ideas about this?
Thank you
Nelson