B
Brian
Is there a way to format a character in the prompt for an input box to give
the user a clue concerning valid entry in the InputBox? I am trying to get
away from using the parentheses to indicate the key character to input for
the selection:
Dim UserResponse As String
Dim MsgBoxText As String
MsgBoxText = MsgBoxText & "(A)pply changes"
MsgBoxText = MsgBoxText & Chr(13)
MsgBoxText = MsgBoxText & "(D)iscard changes"
MsgBoxText = MsgBoxText & Chr(13)
MsgBoxText = "(R)everse stops and review"
TryAgain: 'retry point if user enters invalid data
UserResponse = InputBox(MsgBoxText, "", "D")
If UserResponse = "" Then Exit Sub 'user canceled
If InStr("ADR", UserResponse) = 0 Then GoTo TryAgain 'invalid entry
Select Case UserResponse
Case "A"
'approve changes
Case "D"
'discard changes & close
Case "R"
'revers the stop order & go back to InputBox for further instruction.
End Select
the user a clue concerning valid entry in the InputBox? I am trying to get
away from using the parentheses to indicate the key character to input for
the selection:
Dim UserResponse As String
Dim MsgBoxText As String
MsgBoxText = MsgBoxText & "(A)pply changes"
MsgBoxText = MsgBoxText & Chr(13)
MsgBoxText = MsgBoxText & "(D)iscard changes"
MsgBoxText = MsgBoxText & Chr(13)
MsgBoxText = "(R)everse stops and review"
TryAgain: 'retry point if user enters invalid data
UserResponse = InputBox(MsgBoxText, "", "D")
If UserResponse = "" Then Exit Sub 'user canceled
If InStr("ADR", UserResponse) = 0 Then GoTo TryAgain 'invalid entry
Select Case UserResponse
Case "A"
'approve changes
Case "D"
'discard changes & close
Case "R"
'revers the stop order & go back to InputBox for further instruction.
End Select