RIAS
asked on
String format
Hello,
How to remove all characters from a string and then add a prefix of 0 to the result.
example:
Str= HJY98
EXPECTED RESULT:
Str=098
Thanks
How to remove all characters from a string and then add a prefix of 0 to the result.
example:
Str= HJY98
EXPECTED RESULT:
Str=098
Thanks
If so then you can do:
»bp
str = System.Text.RegularExpressions.Regex.Replace(str, "\D", "")
»bp
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks experts!!!!
»bp