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. Image for the cookie policy date

How to delete summary grid

Hi, I use summaryrow class for databound grid. Each time when I bind grid to new data source (run query with different parameters) it adds new summary grid but doesn''t remove previous one. How to delete summary grids to display only one which is for the last retrieved grid? Thanks in advance

1 Reply

AD Administrator Syncfusion Team July 20, 2004 07:24 PM UTC

Try changing summaryGrid to public so you can access it from your form through the summaryRow object. With that change, here is a button handler that completely seems to completely reload a new summaryRow object in the sample from the KB sample. private void button1_Click(object sender, EventArgs e) { this.gridDataBoundGrid1.BeginUpdate(); this.gridDataBoundGrid1.Focus(); this.gridDataBoundGrid1.ResetGridBounds(); this.gridDataBoundGrid1.Controls.Remove(this.sumRow.summaryGrid); this.sumRow.summaryGrid.Dispose(); this.gridDataBoundGrid1.Refresh(); Form3_Load(sender, e); this.gridDataBoundGrid1.EndUpdate(); }

Loader.
Up arrow icon