MXL5: "Not Enough Memory" Using SHOW.BAR Function in Macro

ID: Q133334

The information in this article applies to:

SYMPTOMS

In Microsoft Excel for the Macintosh, version 5.0, when you use the SHOW.BAR() function in a macro, you may receive the following error message

   Not enough memory.
   Continue without Undo?

followed by the following error message:

   Not enough memory

When you click OK in these error messages, the active macro sheet may not be redrawn completely.

CAUSE

This behavior occurs when you use the SHOW.BAR function in a Microsoft Excel version 4.0 Macro sheet with a bar_num argument value of 7, 8, or 9.

The SHOW.BAR function displays the menu bar specified by the bar_num argument. The bar_num argument values 7-9 are reserved for shortcut menus and are not valid values to use with the SHOW.BAR function.

Although these are not valid values for the bar_num argument, you should not receive a "Not enough memory" error message when you use the SHOW.BAR function with these values. When you run a macro in Microsoft Excel for Windows that contains the function SHOW.BAR() with a bar_num argument value of 7, 8, or 9, a macro error is returned as expected.

WORKAROUND

To avoid this problem, use the SHOW.BAR function with valid argument values, such as 1-6 and 10-12. For more information about the context for using these arguments, see the SHOW.BAR topic in Microsoft Excel Macro Functions Help.

STATUS

Microsoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. This problem was corrected in Microsoft Excel 98 Macintosh Edition.

REFERENCES

For more information about SHOW.BAR, choose the Search button in MS Excel Macro Functions Help and type:

   SHOW.BAR function

Additional query words: 5.00 5.00a XL5
Keywords          : kbmacro kbprg PgmOthr xlmac 
Version           : MACINTOSH:5.0,5.0a
Platform          : MACINTOSH
Issue type        : kbbug
Solution Type     : kbfix

Last Reviewed: February 4, 1998