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.

How to clear GridDataBoundGrid in c#

Thread ID:

Created:

Updated:

Platform:

Replies:

117433 Oct 20,2014 07:28 AM Oct 24,2014 07:29 AM Windows Forms 1
loading
Tags: GridDataBoundGrid(Classic)
Venkaiah
Asked On October 20, 2014 07:28 AM

Hi viewers ,

 I am very new to Syncfusion controls  let you help please 
 How I will clear Data in the GridDataBoundGrid using c#  in the "New" button click ;
( I am trying gdbgdata.datasource =null;,gdbgdata.model.rows.clear()) but its not working 
how i will finish this one please help me 
                                                        thank you in Advance 

Anish George [Syncfusion]
Replied On October 24, 2014 07:29 AM

Hi Venkaiah,

 

Thank you for using syncfusion products.

 

We would like to suggest you to use the ClearCells method for clearing the particular range of cells. Please make use of the below code snippet in you button click event for clearing a particular cell or range of cells.

 

C#:

//Clear the whole grid.
this.gridDataBoundGrid1.Model.ClearCells(GridRangeInfo.Table(),true); 

//Clear the 2th Row.
this. gridDataBoundGrid1.Model.ClearCells(GridRangeInfo.Row(2),true); 

//Clear the 2th Column
this. gridDataBoundGrid1.Model.ClearCells(GridRangeInfo.Col(2),true);

//Clear the (2,2) cell
this. gridDataBoundGrid1.Model.ClearCells(GridRangeInfo.Cell(2,2),true);

 

 

Please let us know if you need any further assistance.

 

Regards,

Anish


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.

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.

;