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

How to clear the entire data in GridDataBoundGrid

Thread ID:





117193 Sep 2,2014 04:18 AM UTC Sep 12,2014 04:02 AM UTC WinForms 3
Tags: GridDataBoundGrid(Classic)
Asked On September 2, 2014 04:18 AM UTC

i tried with this code to clear all the cells Data.. But it's not working Properly....
foreach (Control ctrl in clrctrls)
    if (ctrl.GetType() == typeof(GridDataBoundGrid))
             GridDataBoundGrid Gdbg = ctrl as GridDataBoundGrid;
thanks in Advance.....

Maniratheenam Sehar [Syncfusion]
Replied On September 4, 2014 04:54 AM UTC

Hi Narry,


Thank you for your interest in Syncfusion Products.



Clearing entire data in GridDataBoundGrid

We would like to let you know that we can clear the entire data of a cell in the grid by using the ClearCells method. Please refer the below code snippet.


this.gridDataBoundGrid1.Model.ClearCells(GridRangeInfo.Table(), true);

where the first argument denotes the range of cells that has to be cleared.

Second argument is a Boolean value. True, if you want to clear all the cell information. False, if you want to clear only the text.


Please let us know, if you have any concerns.



ManiRatheenam S

Replied On September 10, 2014 07:11 AM UTC

thanks for your reply.
With your code also i'm not getting clear the all cells data in griddataboundgrid. if it is possible please drop me some example as a attachment. thanks a lot...

Maniratheenam Sehar [Syncfusion]
Replied On September 12, 2014 04:02 AM UTC

Hi Narry,



Sorry for the delay caused.


I’ve attached a sample for your better convenience.

Please let us know, if you’ve any concerns.



ManiRatheenam S

Attachment: GDBsample_d22c9840.zip


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