you will also need to handle it if they type something other than an integer.Sub MainProc()
Dim strValue As String
Dim i As Integer
On Error GoTo YouBwokedIt
strValue = InputBox("Please enter an Integer", "theswamp.org", 1)
i = MakeTen(CInt(strValue))
MsgBox i
LeavingOnAJetTrain:
Exit Sub
YouBwokedIt:
Select Case Err.Number
Case 13
Err.Clear
strValue = InputBox("Hint: An Integer is a number" & vbCrLf & "Please enter an Integer", "theswamp.org", 1)
Resume
Case Else
MsgBox "Oh my god...It's full of stars."
GoTo LeavingOnAJetTrain
End Select
End Sub
Do you really want an integer? That would be whole numbers larger than -32,768 and smaller than 32,767 only. If you need numbers outside that range or decimals, you might want to go with doubles instead.