We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Disable copy, paste in diagram: Angular 7+, TypeScript 3+


Is there a neat way of blocking(only) the ctrl+c, & ctr+v functionality after selecting node(s)?
I tried using your "CommandManagerModel(see 1.)" and returning false based upon the keys, but this doesnt not seem to work.
Is there another way?

thank you in advance!


Laurens Albers

3 Replies

RT Ramya Thirugnanam Syncfusion Team May 10, 2019 11:11 AM UTC

Hi Laurens,  
Thanks for contacting Syncfusion support. 
We can disable the commands by overring the command manager. Please find the code example to disable the keyboard commands.  
public commandManager: CommandManagerModel = {  
commands: [{  
name: 'paste',  
canExecute: (): boolean => {   
return false;  
Ramya T  

LA Laurens Albers May 10, 2019 12:04 PM UTC


I was very close it seems, but now thanks to your input it works.

Have a nice day/weekend!



RT Ramya Thirugnanam Syncfusion Team May 10, 2019 12:23 PM UTC

Hi Laurens, 
Thanks for your update. 
Ramya T 

Live Chat Icon For mobile
Up arrow icon