Forum

Disable right-click...
 
Notifications
Clear all

Disable right-click on slicers in Excel

6 Posts
5 Users
0 Reactions
300 Views
(@mr-bean)
Posts: 3
Active Member
Topic starter
 

Dear All

Is there any way to disable the right-click on slicers in Excel.

I have managed to lock or/and disable most of the Excel functionality on my dashboard but, the slicers are still accessible from the right-click.

Any direction would be appreciated.

Regards,

 
Posted : 21/03/2021 5:56 pm
(@catalinb)
Posts: 1937
Member Admin
 

Short answer: No.

There are no events associated to slicers that can detect if a user right clicked on a slicer.

 
Posted : 22/03/2021 1:29 am
(@khatikvasim13)
Posts: 24
Eminent Member
 

1) First insert the shape (rectangle) then move to slicer this shape 

2) Group the together and name the Group

3) then write the code worksheet event

Like

Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As Boolean)
Sheet1.Shapes.Range(Array("JobGrp")).Visible = msoTrue
End Sub

Private Sub Worksheet_BeforeRightClick(ByVal Target As Range, Cancel As Boolean)
Sheet1.Shapes.Range(Array("JobGrp")).Visible = msoFalse
End Sub

 
Posted : 22/03/2021 3:07 am
(@debaser)
Posts: 836
Member Moderator
 

What exactly are you trying to prevent?

 
Posted : 22/03/2021 5:47 pm
(@khatikvasim13)
Posts: 24
Eminent Member
 

YES see the the sheet1 Double Click Show the slicer and right click hide

 
Posted : 23/03/2021 12:27 am
(@emad-nessim)
Posts: 1
New Member
 

Hi gents,

I am not sure what this code is doing, once I right claik on a cell the slicer disappears.

You know, I am keeping looking for a solution for the same subject made by @ Greg Malek.

 

I am looking for a way or a code to disable the slicer right-click when I protect a sheet.

 

I have the code to disable the cells right-click, but the Slicer even after protecting the sheet is still allowing for right-click and then unwanted changes.

 

If I locked the slicer from the size and properties, then no filtering!

 

Please help me to solve this issue

 
Posted : 04/08/2021 2:57 pm
Share: