Results 1 to 5 of 5
  1. #1
    Plutonium Lounger Leif's Avatar
    Join Date
    Dec 2000
    Location
    U.K.
    Posts
    14,010
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Prompt for document properties (2000+)

    I want to prompt myself and other users to enter a Title into the document properties 'Title' field (manually accessed through File > Properties > Summary) when doing a Save As... to ensure the Title is updated as appropriate.

    Is there a way to trap the BeforeSaveAs Event to prompt the user to check/edit the title?

    Then I seem to be able to invoke the Properties window with Dialogs(wdDialogFileSummaryInfo).Display but it doesn't seem to accept any changes...

    (I assume the Tools > Options > Save 'Prompt for document properties' option only applies if it is a new document with a previously un-edited Title?)

    TIA.

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Prompt for document properties (2000+)

    Create the following macro:
    <code>
    Sub FileSaveAs()
    Dialogs(wdDialogFileSummaryInfo).Show
    Dialogs(wdDialogFileSaveAs).Show
    End Sub
    </code>
    If you store this macro in a module in a document, it will hijack the File | Save As menu option in that document only.
    If you store it in a module in Normal.dot, it will do so for all documents.

  3. #3
    Plutonium Lounger Leif's Avatar
    Join Date
    Dec 2000
    Location
    U.K.
    Posts
    14,010
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Prompt for document properties (2000+)

    That simple, huh? Thanks <img src=/S/grin.gif border=0 alt=grin width=15 height=15>

    I take it I don't need to actually insert a module - it seems to work OK just inserted in ThisDocument...?
    Attached Images Attached Images
    • File Type: gif x.gif (6.9 KB, 0 views)

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Prompt for document properties (2000+)

    Although the code will work if placed in ThisDocument, I'd still recommend storing it in a standard module.
    If things go wrong, you can delete standard modules.
    It is not possible to delete ThisDocument. I'd only use it for the Document events Document_New, Document_Open and Document_Close.

  5. #5
    Plutonium Lounger Leif's Avatar
    Join Date
    Dec 2000
    Location
    U.K.
    Posts
    14,010
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Prompt for document properties (2000+)

    Gotcha. Thanks again.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •