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

convert grid row index to underlying datarow

Thread ID:

Created:

Updated:

Platform:

Replies:

13124 Apr 21,2004 05:59 AM UTC Apr 21,2004 08:32 PM UTC WinForms 1
loading
Tags: GridControl
Vincent Lo
Asked On April 21, 2004 05:59 AM UTC

hi, I think this must have been written somewhere in your knowledge base but could you point me to the right direction?

Administrator [Syncfusion]
Replied On April 21, 2004 08:32 PM UTC

There are KB''s on locating the DataRow at the current position, but not one on getting the DataRow at an abitrary index. Here is code that I think will locate the DataRow at a given grid row index, say rowIndex. CurrencyManager cm = (CurrencyManager) this.BindingContext[this.grid.DataSource, this.grid.DataMember]; int pos = this.grid.Binder.RowIndexToPosition(rowIndex); DataRowView drv = cm.List[pos] as DataRowView; DataRow dr = drv.Row;

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

;