Page 1 of 2 12 LastLast
Results 1 to 15 of 24
  1. #1
    4 Star Lounger
    Join Date
    Jan 2001
    Location
    Atlanta
    Posts
    568
    Thanks
    7
    Thanked 1 Time in 1 Post

    Can Moveable Toolbars be Bolted Into Place? (97)

    I HATE the moveable toolbars/menus in Office. I'm all the time clicking and accidently dragging a menu or toolbar. I would love for them to go back to the 95 way of sticking in place. Can that be done?

    Ronny
    Ronny Richardson

  2. #2
    Silver Lounger Charles Kenyon's Avatar
    Join Date
    Jan 2001
    Location
    Sun Prairie, Wisconsin, Wisconsin, USA
    Posts
    2,049
    Thanks
    124
    Thanked 119 Times in 116 Posts

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    Hi Ronny,

    Yes and no...

    Simplest way I can think of would be to open Normal.dot and remove all of your menus and toolbars (don't delete them - just uncheck them). The main menubar won't uncheck.

    Then record a macro adding them back. Name the macro AutoExec and it will run each time you start Word. The macro can be stored in either Normal.dot or in a different global template. (Things get really interesting though, when multiple global templates start doing this!)
    Charles Kyle Kenyon
    Madison, Wisconsin

  3. #3
    BAM
    Guest

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    Hi Ronny,

    This code will do what you want:

    CommandBars("Standard").Protection = msoBarNoMove

    Since this only needs to be ran once for each toolbar you wish to change, you can run the code without creating a macro. However you may want to save the information for future reference.

    To the code:
    - Copy/paste from this post
    - In Word press <Alt F11> to open the VBA editor
    - Press <Ctrl G> to open an immediate window
    - Paste the code
    - Place your cursor at the end and press <Enter> to run it
    - Change the toolbar name and run the code again

    Note - Change msoBarNoMove to msoBarNoProtection to return to the default settings
    ~~~~~~~~~~~~~~
    Cheers!

  4. #4
    4 Star Lounger
    Join Date
    Jan 2001
    Location
    Atlanta
    Posts
    568
    Thanks
    7
    Thanked 1 Time in 1 Post

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    This is great! I use two toolbars (Standard and Formatting) so I created a two line AutoExec macro and they now stay in place just like I want. Is there a similar command I can add to lock down the menu as well?

    Thanks a bunch
    Ronny
    Ronny Richardson

  5. #5
    BAM
    Guest

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    Hi Ronny,

    As I previously indicated, this should be a one-time action. Word stores this information the WordDataToolbars value of the Registry so if you are able to write changes to that branch (which you should) then the AutoExec macro isn't necessary. <img src=/S/smile.gif border=0 alt=smile width=15 height=15>

    As of Word 97, the menu bar, toolbars and shortcut menus are considered Command bars. They all fall in the same collection, however the Type property of the object specifies whether or not it is a msoBarTypeMenuBar, msoBarTypeNormal (Toolbar), or msoBarTypePopup.

    So the code will work for your menu bar too, just use the command bar name "Menu Bar".
    ~~~~~~~~~~
    Cheers!

  6. #6
    4 Star Lounger
    Join Date
    Jan 2001
    Location
    Atlanta
    Posts
    568
    Thanks
    7
    Thanked 1 Time in 1 Post

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    I ran it with "Menu Bar" and it worked great. I also deleted the AutoExce macro and they stayed fixed. I'll set up some macro to store the commands in case they ever come unfixed.

    I also wanted the same effect in Excel so I ran the commands in Excel. The "Formatting" and "Standard" worked fine and they stayed in place when I exited and restarted Excel. I know this is not the Excel forum but the "Menu Bar" that worked in Word bombed in Excel. Would you know what I need to change in Excel?

    Ronny
    Ronny Richardson

  7. #7
    BAM
    Guest

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    Hi Ronny,

    Glad it's working for you! <img src=/S/smile.gif border=0 alt=smile width=15 height=15>

    To determine the name of a command bar, just right-click a toolbar and select Customize. You'll find all the names in the Toolbars list. So in Excel the menu bar is called "Worksheet Menu Bar"

  8. #8
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Yilgarn region of Toronto, Ontario
    Posts
    5,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    As usual, I stand on your shoulders ....

    <pre>Sub udf_LockToolbars()
    ' Procedure : udf_LockToolbars
    ' Description: Lock all visible toolbars into place.
    ' Copyright: Chris Greaves Inc.
    ' Inputs: None
    ' Returns: Nothing
    ' Assumes: You have docked all visible toolbars where you'd like them set in CONCRETE!
    ' Side Effects: The "move" tag at the LH end of each toolbar will disappear.
    ' Tested: By a call from the user.
    Dim cb As CommandBar
    For Each cb In CommandBars
    If cb.Visible Then
    Call NoMove(cb.Name)
    Else
    End If
    Next cb
    End Sub
    Public Function NoMove(strCommandBar As String)
    CommandBars(strCommandBar).Protection = msoBarNoMove
    End Function

    </pre>


  9. #9
    Lounger
    Join Date
    Mar 2001
    Location
    NSW, Australia
    Posts
    35
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    Thanks Chris - as usual, your information is invaluable, it's great to have immovable toolbars now.
    <img src=/S/cool.gif border=0 alt=cool width=15 height=15>

  10. #10
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Yilgarn region of Toronto, Ontario
    Posts
    5,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    Yup. The macro to un-lock all visible toolbars was left as an exercise for the reader (grin!)

  11. #11
    BAM
    Guest

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    <<As usual, I stand on your shoulders ....>>

    Yewouch! Those spikes sure do hurt! <img src=/S/rofl.gif border=0 alt=rofl width=15 height=15>

  12. #12
    Lounger
    Join Date
    Mar 2001
    Location
    NSW, Australia
    Posts
    35
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    Aha .. thanks to BAM earlier - replace msoBarNoMove with msoBarNoProtection
    Thanks again everyone

  13. #13
    Platinum Lounger
    Join Date
    Dec 2000
    Location
    Queanbeyan, New South Wales, Australia
    Posts
    3,730
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    Or the lazy typist's version:<pre>Public Function YesMove(strCommandBar As String)
    With CommandBars(strCommandBar)
    If (.Protection And msoBarNoMove) = 0 Then
    Else
    .Protection = .Protection - msoBarNoMove
    End If
    End With
    End Function</pre>

    Subway Belconnen- home of the Signboard to make you smile. Get (almost) daily updates- follow SubwayBelconnen on Twitter.

  14. #14
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Yilgarn region of Toronto, Ontario
    Posts
    5,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    <P ID="edit"><FONT SIZE=-1>Edited by gwhitfield on 24-Jul-01 22:11.</FONT></P>split long line in "pre" tag

    They're not Spike's, they're my toenails - I'm scared stiff of heights .....

    Not only my hair is falling out, my mind is going too.

    I used to know how to mask out a bit. Right now I'm clearing the '4' bit in the followintg manner because it works. I think I should be XOR'ing it or something. Task is to set the '4' bit to zero, regardless of its current value ...

    <pre>Public Function YesMove(strCommandBar As String)
    If (CommandBars(strCommandBar).Protection And msoBarNoMove) = 0 Then
    Else
    CommandBars(strCommandBar).Protection = _
    CommandBars(strCommandBar).Protection - msoBarNoMove
    End If
    End Function
    </pre>


  15. #15
    Platinum Lounger
    Join Date
    Feb 2001
    Location
    Yilgarn region of Toronto, Ontario
    Posts
    5,453
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Can Moveable Toolbars be Bolted Into Place? (97)

    > Or the lazy typist's version:


    Yabbut, I'm looking for the xOr lazy typist's version!

Page 1 of 2 12 LastLast

Posting Permissions

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