I have problem with my code. It prompts the user to enter in their name. If they select OK without entering in their name, they are given a different message and asked continuiously until they supply a name.
My problem is that the cancel button on the input box does not work. It continues to ask for a name. Here is the code as I have it in my functon
Public Function Input_User_Name()
Input_User_Name = InputBox("Please enter your name.")
If Input_User_Name = "" Then
Do Until Input_User_Name <> ""
Input_User_Name = InputBox("You MUST enter your name before continuing. Please enter your name.")
Loop
End If
strInput_User_Name = Input_User_Name
End Function
Thanks!
My problem is that the cancel button on the input box does not work. It continues to ask for a name. Here is the code as I have it in my functon
Public Function Input_User_Name()
Input_User_Name = InputBox("Please enter your name.")
If Input_User_Name = "" Then
Do Until Input_User_Name <> ""
Input_User_Name = InputBox("You MUST enter your name before continuing. Please enter your name.")
Loop
End If
strInput_User_Name = Input_User_Name
End Function
Thanks!