Double with/without format : Double Format « Data Type « VB.Net Tutorial






public class Test
   public Shared Sub Main
        Dim n As Double

        n = 12
        n /= 7

        Console.WriteLine("Without formatting: " & n)

        Dim s As String
        s = String.Format("{0:n3}", n)

        Console.WriteLine("With formatting: " & s)


   End Sub
End class
Without formatting: 1.71428571428571
With formatting: 1.714








2.10.Double Format
2.10.1.Double with/without format
2.10.2.Double format: #,###.###000
2.10.3.Double format: F2