3
votes

I'm trying to make it so that when a user clicks the "X" in the top right corner of a WORD document, the prompt "would you like to save changes?" does not come up and the document is not saved. I have found many solutions for Excel, but I have not been successful trying to apply them to Word...

Thanks in advance for any help!

EDIT: I want this to apply to only one document. The .docm is set up as a ReadOnly (to allow Kill-ing itself); it has 2 buttons, 1 for saving as a .pdf form for retain, and 1 to save as a revision and not a completed form. I want to disable the prompt when someone uses the "X" to force saved revision tracking.

1
Might help if you added a little context. Do you want this to apply to all documents at all times, or just one specific document? If you set a document's Saved property to true then Word will not prompt for a save on closing it, as long as there's been no change since you set that property. - Tim Williams

1 Answers

8
votes

Put this in your ThisDocument Object under MicrosoftWordObjects for the file in question.

Make sure it doesn't go into the Normal section

Private Sub Document_Close()
    Me.Saved = True
End Sub

Putting this in the Normal section will turn off the Save As functionality for all documents you open on your instance of Word.