Why when I do:
"1.000.000,00".replace('.','');
It returns me:
"1000.000,00"
How do I make it work with all the characters? which would look like this: "1000000,00"
Why when I do:
"1.000.000,00".replace('.','');
It returns me:
"1000.000,00"
How do I make it work with all the characters? which would look like this: "1000000,00"
I'm using the code below at this time. The %code% is obtained, but does not eliminate the masks to make the comparison in %code% . Anyone have any suggestions?
%pre%You can get the value of %code% in two ways depending on what you need:
Permanent
In your MaskedTextBox change the value of the property %code% to %code% . This way, you can use %code% (anywhere) and the value returned will be the text without the mask.
Temporary
If you need the value with the mask in other parts of the code and want to remove the mask only for %code% you can do the following:
%pre%Note: None of the solutions change the visual appearance of %code% .
Example:
An example of the code you can use within the event of a button (tested in VS2013, .NET4.5):
%pre%