Bug: Office 2007 WindowActivate event fails to fire in a footnote

J

john

When using "Normal View", in previous versions of Office (prior to Office
2007), if you set up a WindowActivate event handler, and switched the focus
back and forth between the main document area and the footnotes pane, the
event would fire.

In Office 2007, the WindowActivate event will not fire when you enter into
the footnote pane in "Draft View". However, if you use an older document
format such as .doc, Word apparently is in "compatibility mode" and the event
will fire.

To reproduce the problem under office 2007:

1) Create a new document
2) add a module to the project and use the following code

Public cls As New Class1

Sub init()
Set cls.app = Application
End Sub

3) add a new class (the name will default to Class1) with the following code:

Public WithEvents app As Application

Private Sub app_WindowActivate(ByVal Doc As Document, ByVal Wn As Window)
MsgBox "activate"
End Sub

4) Run the init() macro to "register" for WindowActivate events
5) Go to "Draft View"
6) Enter some text followed by a footnote.
7) Double click on the foot note number and the footnotes area should appear.
8) Use the mouse to place the cursor into the main text area, and then into
the footnote pane.

Expected result:
A dialog box that says "activate" should appear when clicking into both areas

Actual result:
Only clicking in the main text area makes the dialog appear
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top