ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Right Mouse Click (https://www.excelbanter.com/excel-discussion-misc-queries/231691-right-mouse-click.html)

StephenD

Right Mouse Click
 
Can I modify the right mouse click options?

Preferably I would like to do this without VBA, however . . if that is the
only way then how would I add Paste Special Formulas as a single option
(mouse click) without having to navigate into Paste Special options window?

I would like this option to be available to all of my workbooks.


Thanks in advance for any help you can provide,


Stephen




Dave Peterson

Right Mouse Click
 
How about an alternative?

Mmaybe you can just add an icon to your favorite toolbar (xl2003 and below)
or to the QAT in xl2007:

Tools|customize|Commands tab
Scroll down on the right hand side and drag "paste values" to your favorite
toolbar.



StephenD wrote:

Can I modify the right mouse click options?

Preferably I would like to do this without VBA, however . . if that is the
only way then how would I add Paste Special Formulas as a single option
(mouse click) without having to navigate into Paste Special options window?

I would like this option to be available to all of my workbooks.

Thanks in advance for any help you can provide,

Stephen


--

Dave Peterson

Gary''s Student

Right Mouse Click
 
If you change you mind about VBA, consider the following three macros:

Sub FormulaPaster()
ActiveCell.PasteSpecial Paste:=xlPasteFormulas
End Sub


Sub AddShortcutMenuItems()
Dim new_menu_item As CommandBarButton
Call DeleteShortcutMenuItems
With Application.CommandBars("Cell")
Set new_menu_item = .Controls.Add(Type:=msoControlButton, befo=1)
With new_menu_item
.Caption = "&Paste Formula"
.OnAction = "FormulaPaster"
.Style = msoButtonIconAndCaption
.FaceId = 8
End With
End With
End Sub



Sub DeleteShortcutMenuItems()
On Error Resume Next
With Application.CommandBars("Cell")
.Controls("&Paste Formula").Delete
End With
End Sub


Running AddShortcutMenuItems will add the option to the right-click menu.

DeleteShortcutMenuItems will remove the option.

FormulaPaster does the pasting
--
Gary''s Student - gsnu200854


"StephenD" wrote:

Can I modify the right mouse click options?

Preferably I would like to do this without VBA, however . . if that is the
only way then how would I add Paste Special Formulas as a single option
(mouse click) without having to navigate into Paste Special options window?

I would like this option to be available to all of my workbooks.


Thanks in advance for any help you can provide,


Stephen




StephenD

Right Mouse Click
 
All - sorry I did not get back sooner (I was away) but I wanted to thank you
for your all of your help. It looks as if I will be taking the VBA approach.

"Gary''s Student" wrote:

If you change you mind about VBA, consider the following three macros:

Sub FormulaPaster()
ActiveCell.PasteSpecial Paste:=xlPasteFormulas
End Sub


Sub AddShortcutMenuItems()
Dim new_menu_item As CommandBarButton
Call DeleteShortcutMenuItems
With Application.CommandBars("Cell")
Set new_menu_item = .Controls.Add(Type:=msoControlButton, befo=1)
With new_menu_item
.Caption = "&Paste Formula"
.OnAction = "FormulaPaster"
.Style = msoButtonIconAndCaption
.FaceId = 8
End With
End With
End Sub



Sub DeleteShortcutMenuItems()
On Error Resume Next
With Application.CommandBars("Cell")
.Controls("&Paste Formula").Delete
End With
End Sub


Running AddShortcutMenuItems will add the option to the right-click menu.

DeleteShortcutMenuItems will remove the option.

FormulaPaster does the pasting
--
Gary''s Student - gsnu200854


"StephenD" wrote:

Can I modify the right mouse click options?

Preferably I would like to do this without VBA, however . . if that is the
only way then how would I add Paste Special Formulas as a single option
(mouse click) without having to navigate into Paste Special options window?

I would like this option to be available to all of my workbooks.


Thanks in advance for any help you can provide,


Stephen




StephenD

Right Mouse Click
 
Thanks Dave. I did consider that but I really like the convenience of mouse
button actions as they don't require me to move from the active cell I am
working with.

"Dave Peterson" wrote:

How about an alternative?

Mmaybe you can just add an icon to your favorite toolbar (xl2003 and below)
or to the QAT in xl2007:

Tools|customize|Commands tab
Scroll down on the right hand side and drag "paste values" to your favorite
toolbar.



StephenD wrote:

Can I modify the right mouse click options?

Preferably I would like to do this without VBA, however . . if that is the
only way then how would I add Paste Special Formulas as a single option
(mouse click) without having to navigate into Paste Special options window?

I would like this option to be available to all of my workbooks.

Thanks in advance for any help you can provide,

Stephen


--

Dave Peterson



All times are GMT +1. The time now is 07:49 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com