Results 1 to 6 of 6
  1. #1
    New Lounger
    Join Date
    Jan 2001
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Attaching a toolbar to a workbook (97)

    I have created a workbook for our office as a sort of calendar, designed to be opened normally by one person in order to edit it, and by everyone else as read-only to view it. I created a custom toolbar which I attached to the workbook, with custom macro buttons. However, when I open the workbook from other machines, some show the toolbar with all the buttons, and some show just an 'empty' toolbar (blank, 1 button width wide). In the MS knowledge base it says that you can get this problem if you save the workbook after attaching the toolbar and then change the toolbar - you must then re-attach the toolbar and save again. However, I have done this and still get the same problem. It also doesn't make any difference whether the person is opening read-only or not, it just seems that opening on different machines gives different results. It could be that everyone is on a different service release of Office, but surely this wouldn't be the problem?

  2. #2
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Dublin, Ireland, Republic of
    Posts
    2,697
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Attaching a toolbar to a workbook (97)

    After you re-created the second toolbar, I think it would be necessary to remove the first one from the machines on which it was installed, if it shares the same name, and then open the newly saved workbook.

    You can delete toolbars from, Customize, Toolbars and select the old version and click on delete.

    Andrew C

  3. #3
    Platinum Lounger
    Join Date
    Nov 2001
    Location
    Vienna, Wien, Austria
    Posts
    5,009
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Attaching a toolbar to a workbook (97)

    The poster in this thread had similar problems running a custom toolbar on different machines. As you will see, he ended up using VBA to load the toolbar when the workbook opened. Don't know whether that would be a comfortable solution for your users. (On this kind of issue, there are no major differences between Excel 97 and 2000.) HTH
    Gre

  4. #4
    Platinum Lounger
    Join Date
    Nov 2001
    Location
    Melbourne, Victoria, Australia
    Posts
    5,016
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Attaching a toolbar to a workbook (97)-MULTI-Re: A

    Hi Sally

    I had some of the difficulties you mention, and found the answers in the thread mentioned by Unkamunka (I had the original problem). Your requirements seem a little different to mine, but the essential aspect of the solution in porting to other machines was to make the toolbar genuinely "belong" to the workbook.

    In essence, this means creating it when the workbook opens and destroying it when it closes. This can, I believe, only be done with VBA, and the code given in the thread contains all the info needed. The issues to watch for are *where* the code is placed in terms of the open and close events, as also discussed in the thread.

    Exactly how you implement the selective ability to edit it is another issue. Maybe some sort of password access, since it will necessarily be the same code/toolbar on each machine.

    If you want to do it in VBA, but still can't follow the info in the thread cited, I can post a framework of sorts to show which bits of the code go where. Maybe post your code too, so we can see exactly what you're trying to achieve.

    Alan

  5. #5
    New Lounger
    Join Date
    Jan 2001
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Attaching a toolbar to a workbook (97)-MULTI-Re: A

    Thanks for your response, but I've managed to find a way around my problem without using code. Andrew was right about having to delete the toolbar.

    Basically, I had saved the workbook, then changed the toolbar. Then I tested it by opening the book on another machine - this showed the original, unchanged toolbar. I had to then reattach the changed toolbar, and resave the workbook however, the old toolbar was still showing up on the machine I had tested opening the workbook on. So then I had to go and delete the toolbar from Tools, Customise, on that machine, then close the workbook and reopen it again in order to see the new improved toolbar! Hope this helps anyone else with a similar problem.

  6. #6
    Platinum Lounger
    Join Date
    Nov 2001
    Location
    Melbourne, Victoria, Australia
    Posts
    5,016
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Attaching a toolbar to a workbook (97)-MULTI-Re:

    Having been through a similar saga myself, I can fully understand each & every tedious step you describe. I'm glad you finally got rid of all the old orphaned "apron strings" and the final solution works as required.

    I do believe though that, like my own situation, you might be inviting a bit of a maintenance/update nightmare by adopting the "quick fix" solution. Hard coding the toolbar into the workbook, create on open, and destroy on close, are the best ways to ensure correct operation, regardless of what each machine already carries.

    Maybe the hard coding is worth some consideration, if this is to be an ongoing procedure.

    Alan

Posting Permissions

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