Dear Experts
Variable d contains 703-1 '703 is mounds and 1 is one kg weight![]()
Private Sub CommandButton2_Click() Dim a As Long, b As Long, c As Long, d as string a = 26240 '26240 b = Int(a / 37.324) '703 c = a - b * 37.324 '1 d = Format(b, "&&&&") + "-" + Format(c, "&&") '703-1 End Sub
But I want to show it as 703-01
The last two characters must show in && format, for example
00 instead of 0
05 instead of 5
10 as it is 10
What format should I apply?
Please help
Bookmarks