Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
19541 | Sep 28,2004 04:49 PM UTC | Sep 29,2004 03:58 PM UTC | WinForms | 4 |
![]() |
Tags: GridControl |
int rowPos = this.grid.Binder.RowIndexToPosition(e.RowIndex);
int colPos = this.grid.Binder.ColIndexToField(e.ColIndex);
object val = dataTable1.Rows[rowPos][colPos];
If you are supporting sorting then you need to access the values through the CurrencyManager.
CurrencyManager cm = (CurrencyManager) this.grid.BindingContext[this.grid.DataSource, this.grid.DataMember];
int rowPos = this.grid.Binder.RowIndexToPosition(e.RowIndex);
int colPos = this.grid.Binder.ColIndexToField(e.ColIndex);
object val = ((DataRowView)cm.List[rowPos])[colPos];
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.