DocumentBeforeClose syntax

前端 未结 2 2040
情歌与酒
情歌与酒 2021-01-24 09:16

I really don\'t know the syntax of the DocumentBeforeClose event. Following this page, I should create a class module called \'EventClassModule\' (see also this article). So I d

2条回答
  •  萌比男神i
    2021-01-24 09:44

    X is an instance of the class you created (EventClassModule)

    Your problem is that .App is not a property of EventClassModule. Change

    Set X.App = Word.Application 
    

    to the property you defined in your class

    Set X.appWord = Word.Application 
    

提交回复
热议问题