OFF98: Reset Method of CommandBars Rebuilds Menu Bar Only (184092)
The information in this article applies to:
- Microsoft Excel 98 Macintosh Edition
- Microsoft Word 98 Macintosh Edition
- Microsoft PowerPoint 98 Macintosh Edition
This article was previously published under Q184092 SYMPTOMS
When you reset a menu on a built-in menu bar by using Microsoft Visual
Basic for Applications code, none of the menu items are available.
CAUSE
This problem may occur after you delete a built-in menu from a built-in
menu bar, add it back to the built-in menu bar, and then use the Reset
method to attempt to restore the built-in menu back to its default
settings.
WORKAROUND
To work around this problem, use one of the following methods.
WARNING: Using either of these methods resets all custom menus and
menu items on the specified menu bar.
Method 1: Use the Customize Toolbar Dialog Box- On the View menu, point to Toolbars, and then click Customize.
- In the Customize dialog box, click the Toolbars tab.
- Click the name of the toolbar you want to reset, and then click Reset.
- Click Close.
Method 2: Use Visual Basic for Applications CodeMicrosoft provides programming examples for illustration only, without warranty either expressed or implied. This includes, but is not limited to, the implied warranties of merchantability or fitness for a particular purpose. This article assumes that you are familiar with the programming language that is being demonstrated and with the tools that are used to create and to debug procedures. Microsoft support engineers can help explain the functionality of a particular procedure, but they will not modify these examples to provide added functionality or construct procedures to meet your specific requirements.
To use Visual Basic for Applications code, follow these steps:
- Press OPTION+F11 to start the Visual Basic Editor.
- On the View menu, click Immediate Window.
- In the Immediate window, type the following code, and then
press RETURN.
In Microsoft Excel:
Application.CommmandBars("Worksheet Menu Bar").Reset
In other Microsoft Office programs:
Application.CommmandBars("Menu Bar").Reset
NOTE: The name of the CommandBar object varies according to the product
and its built-in menu bar.
STATUS
Microsoft has confirmed this to be a problem in the Microsoft products
listed at the beginning of this article.
REFERENCES
For more information about Command Bars, click the Office Assistant, type
CommandBars, click Search, and then click to view "CommandBars Collection
Object."
NOTE: If the Assistant is hidden, click the Office Assistant button on the
Standard toolbar. If Microsoft Help is not installed on your computer,
please see the following article in the Microsoft Knowledge Base:
179216 OFF98: How to Use the Microsoft Office Installer Program
Modification Type: | Major | Last Reviewed: | 6/23/2005 |
---|
Keywords: | kbbug kbpending kbProgramming KB184092 |
---|
|