Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
Dim bigNumber As Decimal = 1234567.123456
Console.WriteLine("F2: " & bigNumber.ToString("F2"))
Console.WriteLine("N2: " & bigNumber.ToString("N2"))
'Likewise:
TextBox1.Text = bigNumber.ToString("F2")
End Sub
Results in:
F2: 1234567.12
N2: 1,234,567.12
So use F2 to not include a thousands separator, N2 will include it
sknake
Industrious Poster
4,954 posts since Feb 2009
Reputation Points: 1,764
Solved Threads: 735
you can try this hope it will work for you.
label24.text =Math.Round(a/b, 2)
or try this
label24.text = Format(a/b, "0.00")
try both hope it works with you
emint
Junior Poster in Training
60 posts since Jun 2009
Reputation Points: 10
Solved Threads: 4