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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Intercepting Ctrl-C in a datagrid

Thread ID:

Created:

Updated:

Platform:

Replies:

26274 Mar 18,2005 03:24 AM UTC Apr 14,2005 11:20 AM UTC WinForms 2
loading
Tags: FAQ
simon
Asked On March 18, 2005 03:24 AM UTC

I have a grid with a boolean and a text field I have a problem in that when I have done ''Select(n)'' to select a row and i press Ctrl-C i get the text for the whole row My clipboard ends up like this: true This is the text I want it to just copy the text from one cell. In other words I want to interept Ctrl-C but cannot figure it out. I''ve tried overriding some of the key events etc. but cant quite get it working. the system ctrl-c takes precedence! how can i intercept it

ramnadh
Replied On March 28, 2005 06:03 AM UTC

Hi, Override the ProcessCmdKey(ref Message msg,Keys keydata) in the custom grid you are developing and catch the event Ctrl + C by writing the code if(keyData == (Keys.Control | Keys.C)){ //Do processing as you need and return //true } after writing the logic which you want in the Ctrl + C block return it to true, so the system Ctrl + C won''t be handled. Regards, Ramnadh. >I have a grid with a boolean and a text field > >I have a problem in that when I have done ''Select(n)'' to select a row and i press Ctrl-C i get the text for the whole row > >My clipboard ends up like this: > >true This is the text > >I want it to just copy the text from one cell. In other words I want to interept Ctrl-C but cannot figure it out. > >I''ve tried overriding some of the key events etc. but cant quite get it working. the system ctrl-c takes precedence! > >how can i intercept it

Administrator [Syncfusion]
Replied On April 14, 2005 11:20 AM UTC

>I have a grid with a boolean and a text field > >I have a problem in that when I have done ''Select(n)'' to select a row and i press Ctrl-C i get the text for the whole row > >My clipboard ends up like this: > >true This is the text > >I want it to just copy the text from one cell. In other words I want to interept Ctrl-C but cannot figure it out. > >I''ve tried overriding some of the key events etc. but cant quite get it working. the system ctrl-c takes precedence! > >how can i intercept it

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;