Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How can I enable my macro to only open for one particular workbook

I have created an Excel project for my office, and I want to use a navigation
drop-down toolbar, which will allow us to quickly access other sheets in the
workbook.

I have found a great navigation toolbar (created with VB); however, the only
problem is that the navigation toolbar opens for EVERY worksheet. It always
opens up whenever I click "enable macros."

I only want the navigation toolbar to come on for this one workbook. I'm a
newbie with Excel, so I have no idea how to edit the code to make it open for
only one worksheet.

Thanks for your help!
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default How can I enable my macro to only open for one particular workbook

In your startup template, but workbook code like this:

Private Sub Workbook_Open()

If ActiveWorkbook.Name = "Book2.xls" Then
Application.CommandBars("todo").Visible = True
Else
Application.CommandBars("todo").Visible = False
End If
End Sub


--
Gary''s Student - gsnu200735


"Neale Yonde" wrote:

I have created an Excel project for my office, and I want to use a navigation
drop-down toolbar, which will allow us to quickly access other sheets in the
workbook.

I have found a great navigation toolbar (created with VB); however, the only
problem is that the navigation toolbar opens for EVERY worksheet. It always
opens up whenever I click "enable macros."

I only want the navigation toolbar to come on for this one workbook. I'm a
newbie with Excel, so I have no idea how to edit the code to make it open for
only one worksheet.

Thanks for your help!

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Force users to enable macros when open a workbook Tan New Users to Excel 2 April 15th 07 05:09 PM
Enable macro on opening workbook ASU Excel Discussion (Misc queries) 5 July 3rd 06 05:40 PM
How can force enable macros to be able to open my workbook? kcdonaldson Excel Discussion (Misc queries) 3 December 5th 05 06:16 PM
disable and enable macro execution using VBA in another workbook? keithb Excel Programming 1 August 17th 05 06:21 PM
forcing 'macro enable' on open i-Zapp[_3_] Excel Programming 2 June 22nd 04 03:23 PM


All times are GMT +1. The time now is 10:29 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"