Posted 8 September 2017, 1:37 pm EST
How can I easily stop the user from cutting (Ctrl+X, Shift+Del) and pasting (Ctrl+V, Shift+Ins) on my spreadsheet, but still allow him to copy (Ctrl+C, Ctrl+Ins) to the clipboard?
I have a number of sheets which have complicated formulas and formats and while I want to allow the user to copy the selected range to the clipboard I do not want him to cut the range or paste the clipboard contents into my spreadsheet. I have used the <FONT color=#0000ff size=2>protected</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>override</FONT><FONT size=2> </FONT><FONT color=#0000ff size=2>bool</FONT><FONT size=2> ProcessCmdKey () functionality to stop the user pasting by setting the clipboard contents to null, but i cannot see how to stop the cutting.</FONT>
<FONT size=2> If I use workbook.AutoClipboard = false then this disables all cut, paste and copy keyboard shortcuts, which is more than I want disabled.</FONT>
I am using 4.0.3503.2008
Thanks in anticipation