Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 88
Default disable right click on mouse

is it possible to disable the right click (copy/cut/paste) on a mouse in
excel spreadsheet.

jatman

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22,906
Default disable right click on mouse

In the Immediate Window of the VBE

Application.CommandBars("Cell").Enabled = False 'True to reset

You may want it disabled for one worksheet but not another or one workbook and
not others.

Post back with more details if you want something tailored.


Gord Dibben MS Excel MVP


On Wed, 4 Jun 2008 15:55:03 -0700, jatman
wrote:

is it possible to disable the right click (copy/cut/paste) on a mouse in
excel spreadsheet.

jatman


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 533
Default disable right click on mouse

Application.Commandbars("Cell").Enabled = False

disables the menu completely. Be sure to enable it or the user will be
stuck with it this way.

Another option is just to disable it on a specific sheet:

Private Sub Worksheet_BeforeRightClick(ByVal Target As Range, Cancel As
Boolean)
Cancel = True
End Sub

This must be pasted into the sheet's module (right click sheet tab and click
View Code.

Or for an entire workbook:

Private Sub Workbook_SheetBeforeRightClick(ByVal Sh As Object, ByVal Target
As Range, Cancel As Boolean)
Cancel = True
End Sub

Pasted into the ThisWorkbook module.

--
Jim
"jatman" wrote in message
...
is it possible to disable the right click (copy/cut/paste) on a mouse in
excel spreadsheet.

jatman



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
right mouse click not working VSLAU1 Excel Discussion (Misc queries) 1 March 18th 08 03:55 AM
Disable right mouse click when in Full screen mode clayton Excel Discussion (Misc queries) 2 March 22nd 06 02:53 AM
right mouse click in excel Carol Excel Discussion (Misc queries) 1 January 4th 06 11:21 PM
disable right mouse click on a scatter graph? Engin H. Charts and Charting in Excel 3 June 30th 05 02:57 PM
Each Click of the Mouse D.Parker Excel Discussion (Misc queries) 13 April 28th 05 11:24 PM


All times are GMT +1. The time now is 10:55 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"