DevinSutherland
New Member
- Joined
- Nov 2, 2015
- Messages
- 11
I am having a problem with getting a message box to open and close when I need them to.
lets say text box 1, 2, 3, 4, 5, all have to have something entered in the fields when I click the Submit button. If they do not have something in the field then I want a message box to pop up saying the field needs to be completed. Then I want the Userform to stay open and when the Submit button is clicked again and all fields are completed then I want to unload the userform.
If TextBox1.Value = "" Then MsgBox ("Enter Date"), vbOkCancel
lets say text box 1, 2, 3, 4, 5, all have to have something entered in the fields when I click the Submit button. If they do not have something in the field then I want a message box to pop up saying the field needs to be completed. Then I want the Userform to stay open and when the Submit button is clicked again and all fields are completed then I want to unload the userform.
If TextBox1.Value = "" Then MsgBox ("Enter Date"), vbOkCancel