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

Editing cell value with Delete key

Thread ID:





78553 Dec 18,2008 06:05 AM UTC Dec 18,2008 07:13 AM UTC WinForms 1
Tags: GridControl
champak chaini
Asked On December 18, 2008 06:05 AM UTC

I am using a GridDataBoundGrid, and editing the cell value for a column with text box.

I want to clear the TextValue of the textbox for the cell in edit mode if the delete key is pressed. How to do that?

Also the KeyDown event handler for GridDataBoundGrid is not triggering when Delete key is pressed.

Please reply soon.

Rajadurai C [Syncfusion]
Replied On December 18, 2008 07:13 AM UTC

Hi Champak,

Thanks for your interest in Syncfusion products.

Please try handling the CurrentCellKeyDown event with following code snippet.

void gridDataBoundGrid1_CurrentCellKeyDown(object sender, KeyEventArgs e)
GridCurrentCell cc = this .gridDataBoundGrid1 .CurrentCell;
if (e.KeyCode == Keys.Delete)
if (cc.Renderer is GridTextBoxCellRenderer)
this.gridDataBoundGrid1[cc.RowIndex, cc.ColIndex].CellValue = null;



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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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