none
How to: Open document in VBA without triggering the Document_open event RRS feed

  • Question

  • I want to open a document without running its Document_Open event.

    I know I can do this by holding down the Shift key when opening it so is there a VBA equivalent of this action?

    Otherwise; Excel has an EnableEvents property. Is there an equivalent in Word?

    Thanks.

    Tuesday, March 28, 2017 4:11 AM

All replies

  • Hi FSComp,

    I try to find the alternative approach for EnableEvents property in word document as it is not supported in word.

    but unfortunately there is no any alternative approach is available in word object model for this issue.

    below is the link for the Word object Model you can try to refer.

    Object model (Word VBA reference)

    I find one discussion in one old thread , but it seems that the suggestion is based on using template, you can have a look.

    Disabling code with code (MSWord97/VBA)

    so currently , it looks like it is not possible to block Document_open event from VBA code.

    if you think that this feature needs to be add in word then you can submit your feedback to user voice.

    Welcome to Word's Suggestion Box!

    Regards

    Deepak


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Wednesday, March 29, 2017 12:53 AM
    Moderator