Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
16087 | Jul 6,2004 08:43 AM UTC | Jul 29,2004 12:23 PM UTC | WinForms | 9 |
![]() |
Tags: Grouping |
int dvIndex = dataView.Find(...);
Record r = grid.Table.UnsortedRecords[dvIndex];
grid.Table.CurrentRecord = r;
Another option is if the grid is sorted by that primary key field. Then you can drill down to the group that the record belongs to and in that group then call Records.FindRecord. This works also with non-primary key fields. The grid only needs to be sorted by that field.
// Grouped by Country
GridGroup germanyGroup = (GridGroup) this.groupingGrid1.Table.TopLevelGroup.Groups["Germany"];
Record r = germanyGroup.Records.FindRecord("Aachen");
- or -
// Not grouped:
Record r = this.groupingGrid1.Table.Records.FindRecord("Aachen");
Stefan
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.
This page will automatically be redirected to the sign-in page in 10 seconds.