I would like to be able to 'restore' MS Word's document window using Automation.
I already have the application object and I have tried calling App.Activate. Activate will bring the window to the top of the Window stack but not if Word is minimized. I can set the WindowState to Maximized, Minimized and Normal but what I really need to do is restore the window to the state it was in before the user minimized it (this would be equivalent to the user clicking on the application's button in the taskbar).
Is this possible using Word automation?
I am actually using C++ to to the automation so I am able to call Win32 API functions if required.
If there is not direct way to restore the window then the question becomes, 'how can I get the window handle of the ActiveWindow?'