Hello,
I have created a useform to collect some information in excel. There is a command button at the bottom which then creates and event and copies the data into the associated spreadsheet.
There is one listbox and one text box in the form. I would like some code for a message box to appear if either the list or text box is empty.
For example, if the listbox is empty and the user selects the command button, then a message box appears with the message "please fill in listbox"
if the textbox is empty when the command button is selected, the message appears saying "please fill in textbox"
If both the list box and the text box are complete, then when the command button is clicked the data in the userform will be transferred to the excel spreadsheet.
I have all the other code written already (including how to copy the values into the spreadsheet for the event), I am just struggling with message boxes.
I thank you in advance for your assistance
T15K
Bookmarks