Link to home
Start Free TrialLog in
Avatar of Mark Delorme
Mark DelormeFlag for Canada

asked on

MS Word VBA - Determining Ribbon State on Open Combined with Toggle Event

I have the same issue as another question posted on this site.

I'm having the same issues as Mike235, whereas the calculation of the ActiveWindow.UsableHeight property does not update the value within the same subscript following a .ToggleRibbon event.  There really is quite a paucity of information relating to the .ToggleRibbon script in MS Word, and I've spent a good amount of time looking for a solution.

The basic idea is that the application will recognize the ribbon state (visible or minimized) when the document is opened, and either activate the toggle ribbon command, or do nothing (if the ribbon was already minimized).  Additionally, I would like to have a close event that restores the ribbon to it's original state when the application was opened (i.e. either maximized or minimized).

Very simple to explain, and it also seems like the above code *should* work, although as you've demonstrated, this isn't the case.

I've tried implementing the latter code provided by DrTribos, although this isn't restoring the application window state back to having the ribbon visible when the document is closed and the application is exited.  I've been experiencing these issues in both MS Word 2010 & 2013.

Any further insight would be much appreciated.
ASKER CERTIFIED SOLUTION
Avatar of Anastasia D. Gavanas
Anastasia D. Gavanas
Flag of Greece image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Mark Delorme

ASKER

@xtermie:  This code does not work unfortunately.  I've tried everything; I'm thinking that it might not be possible.
script and suggestions work