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.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Clearing Cells

Thread ID:

Created:

Updated:

Platform:

Replies:

19643 Sep 30,2004 03:32 PM UTC Sep 30,2004 04:38 PM UTC Windows Forms 3
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On September 30, 2004 03:32 PM UTC

How can I clear the contents of a cell using the delete key, I need this to work on currency, textbox and combo cell types.

Administrator [Syncfusion]
Replied On September 30, 2004 03:51 PM UTC

What version of our library are you using? I had no problems selecting cells in the CellTypes\ComboBoxes and CellTypes\Currency samples that we ship, and the pressing the Delete key to clear the cells using 2.1.0.9. Do these samples work for you?

Administrator [Syncfusion]
Replied On September 30, 2004 04:06 PM UTC

I’m using Grid Control version 2.0.5.1of Essential Grid in VB.NET. I notice the clearingcells event does not fire for a single cell, what event should I use to trap this situation? >What version of our library are you using? I had no problems selecting cells in the CellTypes\ComboBoxes and CellTypes\Currency samples that we ship, and the pressing the Delete key to clear the cells using 2.1.0.9. Do these samples work for you?

Administrator [Syncfusion]
Replied On September 30, 2004 04:38 PM UTC

I think this code in a CurrentCellKeyDown event handler should do it.
If e.KeyCode = Keys.Delete _
   And Not Me.gridControl1.CurrentCell.IsEditing _ 
   And Me.gridControl1.Selections.Ranges.Count = 0 Then
      Console.WriteLine("Delete on single cell")
End If

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

;