Archive of Mr Excel Message Board


Back to General Excel archive index
Back to archive home

"Ghost" Toolbar Icons

Posted by JAF on June 30, 2000 1:20 AM
I have a number of macros in my Personal Macro Workbook which I have assigned to new toolbar icons.

Ideally what I want to do is to "ghost" these icons whenever there is no workbook open, but for them to appear as normal when ANY workbook is open.

If this is not possible, is there any VBA code which I could incorporate into my custom macros - something along the lines of "if there is no workbook open then exit sub, else run code"?

Any ideas?


JAF


Re: "Ghost" Toolbar Icons

Posted by Ryan on June 30, 0100 1:26 PM
JAF,
What you'll have to do is write code for an application level event and have it count the number of workbooks and if it is 0 then to hide the toolbar, and if not to have it visible. Hope this helps.

Ryan


This archive is from the original message board at www.MrExcel.com.
All contents © 1998-2004 MrExcel.com.
Visit our online store to buy searchable CD's with thousands of VBA and Excel answers.
Microsoft Excel is a registered trademark of the Microsoft Corporation.
MrExcel is a registered trademark of Tickling Keys, Inc.