Results 1 to 7 of 7
  1. #1
    4 Star Lounger
    Join Date
    May 2004
    Location
    Toronto, Ontario, Canada
    Posts
    425
    Thanks
    5
    Thanked 0 Times in 0 Posts

    adding items to right click (Excel 2000)

    Hi all,
    I want to delete my right click menu, and install my own custom right click menu,

    Can anyone help me get started?

    Thank you in advance.

    Darryl

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: adding items to right click (Excel 2000)

    The context menus (right click menus, shortcut menus) in Excel can only be customized using VBA code. See XL2000: Sample Macros that Customize and Control Shortcut Menus.

    Also see <post#=315446>post 315446</post#>.

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

    Re: adding items to right click (Excel 2000)

    Excel has many different rightclick menues, each for different situations (depends where you rightclick on)
    Which would you need to change?

    You need VBA code to change the rightclick menus.

    Below I've listed the names of the rightclick menus:

    To change the one you get when rightclicking a cell:

    <pre>Sub test()
    Dim cControl As CommandBarControl
    With Application.CommandBars("Cell")
    For Each cControl In .Controls
    cControl.Delete
    Next
    Set cControl = .Controls.Add(msoControlButton, , , , True)
    cControl.Caption = "Test"
    End With
    End Sub

    Sub ResetCommandbar()
    Application.CommandBars("Cell").Reset
    End Sub
    </pre>

    Workbook tabs
    Cell
    Column
    Row
    Cell
    Column
    Row
    Ply
    XLM Cell
    Document
    Desktop
    Nondefault Drag and Drop
    AutoFill
    Button
    Dialog
    Series
    Plot Area
    Floor and Walls
    Trendline
    Chart
    Formula Bar
    PivotTable Context Menu
    Query
    Query Layout
    AutoCalculate
    Object/Plot
    Title Bar (Charting)
    Layout
    Jan Karel Pieterse
    Microsoft Excel MVP, WMVP
    www.jkp-ads.com
    Professional Office Developers Association

  4. #4
    WS Lounge VIP sdckapr's Avatar
    Join Date
    Jul 2002
    Location
    Pittsburgh, Pennsylvania, USA
    Posts
    11,225
    Thanks
    14
    Thanked 342 Times in 335 Posts

    Re: adding items to right click (Excel 2000)

    In addition to the posts listed, an easy way to "disable it" temporarily is to put code into the beforerightclick event. This allows adding your own popup and "cancel" excel's, but does not change it.

    This allows having it only occur when right clicking within a given range. There is some example code in <post#=334534>post 334534</post#>

    Steve

  5. #5
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Salt Lake City, Utah, USA
    Posts
    9,508
    Thanks
    0
    Thanked 6 Times in 6 Posts

    Re: adding items to right click (Excel 2000)

    See also the threads starting with <post#=60552>post 60552</post#> & <post#=103469>post 103469</post#>, especially <!profile=Brooke>Brooke<!/profile>'s contributions.
    -John ... I float in liquid gardens
    UTC -7ąDS

  6. #6
    4 Star Lounger
    Join Date
    May 2004
    Location
    Toronto, Ontario, Canada
    Posts
    425
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Re: adding items to right click (Excel 2000)

    Thank you all!

  7. #7
    Lounger
    Join Date
    Nov 2001
    Location
    Calgary, Alberta, Canada
    Posts
    36
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: adding items to right click (Excel 2000)

    An alternative way?

    1. Design a user form to suit your purpose.
    2. Assign to a shortcut key.
    3. With the appropriate mouse and driver, assign this combination to one of the mouse's buttons.

    I have designed a very personal utility for myself in this way and much prefer the design flexibility that the user form provides when compared to a menu.

    Hope this provides some food for thought,

Posting Permissions

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