FlexGrid for WinForms Task-Based Help > Clearing C1FlexGrid > Clearing Content |
To clear the contents of C1FlexGrid, add the following Clear method. In this example, the code was added to the Click event of the Clear Contents button.
To write code in Visual Basic
Visual Basic |
Copy Code
|
---|---|
Me.C1FlexGrid1.Clear(C1.Win.C1FlexGrid.ClearFlags.Content) |
To write code in C#
C# |
Copy Code
|
---|---|
this.c1FlexGrid1.Clear(C1.Win.C1FlexGrid.ClearFlags.Content); |
Clicking Clear Content clears only the contents, not the styles or UserData of the grid.