Quote:
Originally Posted by menteith
If I open Word (no document opened, just blank page), modify it and choose to close Word, a SaveAs dialog is shown. Is there a chance to show an ordinary Word dialogue asking a question whether a document should be saved or not ot, or to cancel? Currently, in the above-mentioned situation, there is no chance of quitting Word without saving, that is, when I choose not to save, I get back to Word (it does not exit.)
|
You could insert:
If Len(Trim(.Range.Text)) = 1 Then Exit Sub
after:
If .Path = "" Then: If Application.Dialogs(wdDialogFileSaveAs).Show <> -1 Then Exit Sub
in the code I posted.
Quote:
Originally Posted by menteith
If a document exists on, say, harddrive, pendrive etc. and I modify it and choose to save, there is a dialogue box asking whether to save or not. In this situation, saving without asking would be preferred for me
|
Having code that results in the dialogue box opening for every save is the only way I could find to ensure a backup gets created.