This is a migrated thread and some comments may be shown as answers.

Clear button outside radgrid

1 Answer 11 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Ryann
Top achievements
Rank 1
Ryann asked on 03 Dec 2013, 01:58 PM
Hi
I want to set a clear button outside radgrid that refreshes the radgrid and closes all the editforms if any are open. What is the best way to do this?

1 Answer, 1 is accepted

Sort by
0
Accepted
Princy
Top achievements
Rank 2
answered on 03 Dec 2013, 02:11 PM
Hi Ryann,

Please try the following code snippet.

ASPX:
<asp:Button ID="ClearBtn" runat="server" Text="Clear" onclick="ClearBtn_Click"/>

C#:
protected void ClearBtn_Click(object sender, EventArgs e)
{
  RadGrid1.MasterTableView.ClearEditItems();
  RadGrid1.Rebind();
}

Thanks,
Princy
Tags
Grid
Asked by
Ryann
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Share this question
or