Popup when file name is "X" but when it is changed dont create popup

ulpk29

New Member
Joined
Mar 6, 2019
Messages
6
Currently I am using the following in a spreadsheet we use for internal reviews.

Code:
Private Sub Workbook_Open()
MsgBox "Click OK, then please save with your file name before entering information onto the form", vbOKOnly + vbExclamation, "ATTENTION!!!"
End Sub


Is there some language I can use to stop the popup appearing once a user changes the filename from "X" to the standard we use when storing on our server?

Thank you for your input, I really appreciate it.
 

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.
Something like
Code:
Private Sub Workbook_Open()
   If Me.name = "xxx.xlsm" Then
      MsgBox "??"
   End If
End Sub
 
Last edited:
Upvote 0
That did it. Thank you! I just couldn't think of how to write it, but the syntax makes sense now that I see it.
 
Upvote 0
You're welcome & thanks for the feedback
 
Upvote 0

Forum statistics

Threads
1,223,227
Messages
6,170,849
Members
452,361
Latest member
d3ad3y3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top