Results 1 to 4 of 4
  1. #1
    5 Star Lounger
    Join Date
    Jul 2001
    Location
    Terneuzen, Netherlands
    Posts
    895
    Thanks
    0
    Thanked 0 Times in 0 Posts

    WORD Save-event? (Word 97/2000)

    I need to check if a document was saved in WORD. Obviously, I can check the 'activedocument.saved' property (or something similar); however I have a button on a form and want that to be automatically 'Enabled' only if the document is saved. For example, a user is working on a new document (in the auto_open I check if this document already exists, if not I disable the button); as soon as (s)he saves the document I want the button to become available.... therefore I guess I'd need a save-event... Have looked & searched but could not find this...

    A (very) dirty trick would be to enable a timer-event (if that is even possible in Word, I normally use EXCEL there it is... but so is a save-event <img src=/S/cloud9.gif border=0 alt=cloud9 width=25 height=23> ) and check the saved property every so many seconds... as I said, this is hardly good programming... I'm open to your ideas and suggestions!

    EJ

  2. #2
    Plutonium Lounger
    Join Date
    Nov 2001
    Posts
    10,550
    Thanks
    0
    Thanked 7 Times in 7 Posts

    Re: WORD Save-event? (Word 97/2000)

    Can you manipulate your button in the Form Activate event.
    Or is this a modeless user form that remains on the screen whilst the user is editing the document?

    StuartR

  3. #3
    5 Star Lounger
    Join Date
    Jul 2001
    Location
    Terneuzen, Netherlands
    Posts
    895
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: WORD Save-event? (Word 97/2000)

    I hope I understand you right: the button is just in the document, not on a form; it was added from the control toolbox (commandbutton-object).

    Does this answer your question?

  4. #4
    Plutonium Lounger
    Join Date
    Nov 2001
    Posts
    10,550
    Thanks
    0
    Thanked 7 Times in 7 Posts

    Re: WORD Save-event? (Word 97/2000)

    The only way I know to do this is to use what you call "a timer event". You do this in Word with Application.OnTime

    I tried running some code once a second to manipulate buttons on a toolbar once, but the side effects were so horrible that I never shipped it.

    StuartR

Posting Permissions

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