Click here to Skip to main content
16,016,489 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i need to edit a string to look like 4,000,000 using regex and i have been looking around it, but can find no way on it please help i know that i have to declare

using System.Text.RegularExpressions


but from that i have no idea , i have been playing with regex, but i want to as i insert the values into the textbox that it already adds the "," where needed
Posted

1 solution

Google[^] makes developer's life easier.
 
Share this answer
 
Comments
Matt T Heffron 19-Feb-14 13:21pm    
I don't think that's what OP wants.
It looks like they want the punctuation to happen AS the user inputs digits into a control (WPF TextBox, I'd guess).
MashaJoey 20-Feb-14 5:15am    
its not what i wanted, and your correct what you say is what i wanted, but i used that info and compined my windows forms app and created a validation rule that that helped a lot to write, so in a way it helped, i didnt mean to ask for code, more a direction.


.... also google does make a developers life easier

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900