Just wondering if there is a more concise way to write this code. I just need it to put a zero in front of all single digit values, so 1 = 01.
Sub AddaZero()
For i = 1 To 9
If ActiveCell.Value = "1" Then
ActiveCell.Value = "01"
End If
If ActiveCell.Value = "2" Then
ActiveCell.Value = "02"
End If
If ActiveCell.Value = "3" Then
ActiveCell.Value = "03"
End If
If ActiveCell.Value = "4" Then
ActiveCell.Value = "04"
End If
If ActiveCell.Value = "5" Then
ActiveCell.Value = "05"
End If
ActiveCell.Offset(1, 0).Select
Next i
end sub
Bookmarks