extract last value of a string c# code example Example: c# get last character of string mystring.Substring(mystring.Length - 4);