I have a macro that creates a copy of a worksheet (in same workbook) at the click of a button. they select a customer name, hit the button, then it creates a worksheet with the customer name as the ws name. If they already created a ws for that customer, I get a runtime error 1004 but the sheet is created without the customer name. I would like to just change the text in the runtime error message, or add to it. For an easy example...
Sub Error1004_Example()
Worksheets("Sheet2").Name = "Sheet1"
End Sub
I would like the error message for this to read:
"You already created a page for this customer. Please select another customer or change the name of the tab manually."
Bookmarks