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.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Record Number in Grid

Thread ID:

Created:

Updated:

Platform:

Replies:

15055 Jun 10,2004 08:44 AM Jun 11,2004 03:47 AM Windows Forms 2
loading
Tags: Grouping
Jason Hales
Asked On June 10, 2004 08:44 AM

How do I display the record number for each record in a grid. I now about the ShowNavigationBar property but would lke each record to be numbered

Administrator [Syncfusion]
Replied On June 10, 2004 01:56 PM

Hi Jason, You could do this with an unbound column. The CustomSummary example shows how to add an unbound field (the CustomCounter in that sample). In the unboundField_QueryValue method you can then set the record index: private void unboundField_QueryValue(object sender, FieldValueEventArgs e) { if (e.Record is AddNewRecord) return; if (e.Field.Name == "Record") e.Value = e.Record.ParentTable.Records.IndexOf(Record); else if (e.Field.Name == "UnsortedRecord") e.Value = e.Record.ParentTable.UnsortedRecords.IndexOf(Record); } Stefan

Administrator [Syncfusion]
Replied On June 11, 2004 03:47 AM

Thanks again Stefan, that''s exactly what I need ;-) Jason

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;