K
kckar
i have an inputbox on one of my worksheets. on another worksheet i hav
a listof about 40 numbers. i want to be able to cancel the inputbox an
it exits on when i hit the cancel button. when i enter an incorrec
number i want to the box to have another box pop up that says incorrec
id.
my code so far is
Sub boxes()
'sub for user input boxes
Range("f8").Offset(Range("checkoutindex"), 0) = Range("checkoutindex")
Range("g8").Offset(Range("checkoutindex"), 0) = InputBox("Enter Produc
ID #")
Range("a2") = Range("g8").Offset(Range("checkoutindex"))
Range("i8").Offset(Range("checkoutindex"), 0) = InputBox("Ente
Quantity")
End Sub
Private Sub CommandButton1_Click()
'add item button
Range("checkoutindex") = Range("checkoutindex") + 1
boxes
Do While Range("a4") = True
MsgBox ("Incorrect ID #")
boxes
Loop
End Sub
thank yo
a listof about 40 numbers. i want to be able to cancel the inputbox an
it exits on when i hit the cancel button. when i enter an incorrec
number i want to the box to have another box pop up that says incorrec
id.
my code so far is
Sub boxes()
'sub for user input boxes
Range("f8").Offset(Range("checkoutindex"), 0) = Range("checkoutindex")
Range("g8").Offset(Range("checkoutindex"), 0) = InputBox("Enter Produc
ID #")
Range("a2") = Range("g8").Offset(Range("checkoutindex"))
Range("i8").Offset(Range("checkoutindex"), 0) = InputBox("Ente
Quantity")
End Sub
Private Sub CommandButton1_Click()
'add item button
Range("checkoutindex") = Range("checkoutindex") + 1
boxes
Do While Range("a4") = True
MsgBox ("Incorrect ID #")
boxes
Loop
End Sub
thank yo