Module Parsing Sub Main() Console.Write("Enter a decimal amount ==> ") Dim s As String = Console.ReadLine() Console.Write("Use Parse (P) or TryParse (T) ==> ") Dim choice As String = Console.ReadLine().ToUpper() Dim d As Decimal '------------------------------------------------------------- ' use Decimal.Parse '------------------------------------------------------------- If choice = "P" Then Try d = Decimal.Parse(s) Console.WriteLine("Parse was successful") Catch Console.WriteLine("Parse was not successful") End Try End If '------------------------------------------------------------- ' use Decimal.TryParse '------------------------------------------------------------- If choice = "T" Then Dim success As Boolean = Decimal.TryParse(s, d) If success Then Console.WriteLine("TryParse was successful") Else Console.WriteLine("TryParse was not successful") End If End If Console.WriteLine("Press Enter to exit") Console.ReadLine() End Sub End Module