Question

In C#, I use this mask:

$999,999.00

But I need to display the number as $123,123,12.

If I want to put 99.00, I need do 000099.00 I do not want to do it.

And if I use this:

$99.00 

I cannot put a number as $100.00. How can I use the mask for numbers like:

$123,412,341,234.00 
and $99.00
and $9.00

maskedtextbox1.Mask="$999,999.00"
Was it helpful?

Solution

As far as I am concerned there is no way to mask entries with various lengths. It seems you will need to filter it manually.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top