Results 1 to 3 of 3
  1. #1
    Star Lounger
    Join Date
    Aug 2002
    Michigan, USA
    Thanked 0 Times in 0 Posts

    Share Toolbars with other User (2000)

    Can someone please kindly explain to me how I can share a customized toolbar I created with another user? I have an excel spreadsheet I created, and it has one customized NEW toolbar that runs a macro. When I email the spreadsheet to another user, they don't get my toolbar, nor can they select it from the toolbars list. I guess I don't know what to do next to help them out??? Thanks much for your insight, I appreciate it!

  2. #2
    WS Lounge VIP rory's Avatar
    Join Date
    Dec 2000
    Burwash, East Sussex, United Kingdom
    Thanked 229 Times in 210 Posts

    Re: Share Toolbars with other User (2000)

    You have two options really:
    1. Have code in the workbook_open event that builds the toolbar when the workbook is opened.
    2. Attach the toolbar to the workbook. To do this, right-click a toolbar, choose Customize and then on the Toolbars tab there is an Attach option that allows you to attach custom toolbars to a workbook.
    Hope that helps.

    Microsoft MVP - Excel

  3. #3
    Platinum Lounger
    Join Date
    Feb 2001
    Weert, Limburg, Netherlands
    Thanked 0 Times in 0 Posts

    Re: Share Toolbars with other User (2000)

    To add to Rory's advice:

    Excel keeps toolbar and menubar customizations in a file with the extension .xlb. The exact filename depends on Excel version and install, but usually is: Excel9.xlb or Excel.xlb or Username8.xlb.
    Often this file can be found in your WINDOWS directory.

    You can attach a toolbar to a workbook. When this workbook is loaded, XL checks if the toolbar is on the system. If not, it copies the toolbar from the workbook to the system.

    After creating *or changing* the toolbar, you should attach the toolbar to your workbook:

    - activate the workbook to which you want to attach the toolbar
    - Rightclick the toolbar, select 'customize'
    - Click 'Attach' (Toolbars Tab)
    - If the workbook already contains a toolbar by that name, delete it first by clicking on it on the righthand side and choosing Delete.
    - Select your toolbar (on the left) and press 'copy'
    - Save the workbook (optionally: save_as an add-in).

    Also, you should include code that deletes the toolbar when your workbook or add-in is closed, so that when you deliver a new version of your workbook the new toolbar will be used i.s.o the old one. You can do that in the Thisworkbook module, using the Workbook_BeforeClose event:

    Private Sub Workbook_BeforeClose(Cancel as Boolean)
    On Error Resume Next 'In case Toolbar is absent
    End Sub
    Jan Karel Pieterse
    Microsoft Excel MVP, WMVP
    Professional Office Developers Association

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts