how to turn a string into a int c# code example Example: convert string to number C# int x = 0; Int32.TryParse(TextBoxD1.Text, out x);