Excel VBA - DoubleClick Event/Protected Sheet

Jaye Cavallo

Board Regular
Joined
Mar 10, 2022
Messages
51
Office Version
  1. 2016
Platform
  1. Windows
Hello, I have developed a userform that writes data to a worksheet. The userform is working perfectly fine with adding the data to the worksheet. I have implemented a doubleclick event to the worksheet to allowing the user to edit each entry (row) that has been added to the worksheet from the userform. However, I would like to prevent users from editing the worksheet with direct interaction to the worksheet, but allow for a double click event. Is there a way to protect the worksheet, allow for the doubleclick event AND prevent the user from editing/deleting content on the worksheet?

I would appreciate any feedback.
 
protect the worksheet. have to unprotect it to write data from the form, then protect it again.
probably have to allow selecting locked cells. how did you implement the double click - have to check if it works on a protected sheet.
the other way is to have a button to open the form, i am not sure if the button can move with the selection on a protected sheet.
 
Upvote 0

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top