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
close icon

Performance advice....

I have a databound grid which I am populating by iterating through a dataview and calling the following line: this.filteredAppointments.Rows.Add etc.... This grid also has a filterbar: //create the filter bar and display it GridFilterBar theFilterBar; theFilterBar = new GridTextBoxFilterBar(); //create a style for the filter cells that uses TextBox GridStyleInfo style = new GridStyleInfo(); style.ModifyStyle(this.grdAppointments.BaseStylesMap["Header"].StyleInfo, StyleModifyType.Copy); style.CellType = "TextBox"; style.BaseStyle = "Standard"; style.Font.Bold = false; style.BackColor = System.Drawing.Color.LemonChiffon; style.Borders.Bottom = new GridBorder(GridBorderStyle.Dashed); this.grdAppointments.DataSource = this.filteredAppointments; theFilterBar.UnwireGrid(); theFilterBar.WireGrid(this.grdAppointments, style); The current setup works very well for a smaller amount of records. However, when it gets up above a few thousand the performance is unacceptable. Now how can I get the following requirements for say 10000 records: - Load in under 5 seconds - Provide the filter bar I have listed above My guess is I would need to convert it to a virual grid implementation. If I do this, I dont think I can use the databound grid or the filterbar. Cheers, JF

2 Replies

AD Administrator Syncfusion Team December 5, 2003 10:24 PM UTC

I would suspect the Time consuming part of this task may be in the GridFilterBar.CreateUniqueEntries method. This is the place where the code loops though all the values in the column from the grid''s DataTable, and create another datatable holding the unique values for the combobox''s datasource. It might be possible to do this much quicker by using a sql query to get the unique entries directly from the ADO.NET data source. I am not positive on this, but it is something to consider. You might consider using the GridGroupingControl in the 2.0.1.0 beta release. In this release, filtering is supported, but the actual FilterBar is not yet implemented, but it will be. I suspect it will be able to meet your requirements.


JF Jim Frapper December 6, 2003 12:36 PM UTC

Hey Clay, Actually I am not using a combobox at all. I am using the TextBox FilterBar, as referenced in your FAQs. >You might consider using the GridGroupingControl in the 2.0.1.0 beta release. In this release, filtering is supported, but the actual FilterBar is not yet implemented, but it will be. I suspect it will be able to meet your requirements. At this point, I would not like going with a product in beta. Partly because I have to have a solution by Monday. But, I will take a look at that in the next couple of months. Cheers, JF

Loader.
Live Chat Icon For mobile
Up arrow icon