Hi everyone
VB.NET
If i create a string object, how can i take the numerical value in this string object? Is there an easy method of string class?
For example:
String myString;
myString = "sth389";
int ab = myString.XXX ;I want the value of "ab" to be 389 here.
Any suggestions?
Any suggestions?
Graham Shorey42 pointsPosted Dec 11, 2006, 11:14 PM EST
using System.Text.RegularExpressions;
int i = Convert.ToInt32(Regex.Replace("birseyler389", "[^0-9]", ""));