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

How can I display fixed rows count in GridDataBoundGrid?

DataSet contain 100 records. I need to display first 20 records. Best regards.

3 Replies

AD Administrator Syncfusion Team August 3, 2004 08:45 AM UTC

You can set the size of the grid so it can display the first 20 records. this.gridDataBoundGrid1.Size = new Size(this.gridDataBoundGrid1.Size.Width, this.gridDataBoundGrid1.Model.RowHeights.GetTotal(0, 20));


AP Andrey Plinda August 3, 2004 09:57 AM UTC

Sorry, but it''s not working. See attached project. FixedRowCountInGrid_6028.zip


AD Administrator Syncfusion Team August 3, 2004 12:32 PM UTC

You have this.gridDataBoundGrid1.Dock = System.Windows.Forms.DockStyle.Left; This supercedes any explicit sizng of the grid as it is docked left which menas its height is determined by its parent. If you comment out that line (from the designer generated code), the buttons work to show 10 and 20 rows for me.

Loader.
Live Chat Icon For mobile
Up arrow icon