Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
8257 | Oct 29,2003 07:25 PM UTC | Oct 30,2003 03:19 PM UTC | WinForms | 3 |
![]() |
Tags: GridControl |
//get the datacolumn for the 3rd col in grid
string dataTableColumnName = this.gridDataBoundGrid1.GridBoundColumns[2].MappingName;
DataColumn dc = this.dataTable1.Columns[dataTableColumnName];
> //get the datacolumn for the 3rd col in grid
> string dataTableColumnName = this.gridDataBoundGrid1.GridBoundColumns[2].MappingName;
> DataColumn dc = this.dataTable1.Columns[dataTableColumnName];
//the value from the 5 item in the 3rd column.
int item = 5;
CurrencyManager cm = (CurrencyManager)this.BindingContext[this.gridDataBoundGrid1.DataSource, this.gridDataBoundGrid1.DataMember];
object o = cm.List[item];
PropertyDescriptor pd = this.gridDataBoundGrid1.Binder.InternalColumns[2].PropertyDescriptor;
object val = pd.GetValue(o);
Console.WriteLine(val);
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.