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

griddataboundgrid cell data

Thread ID:

Created:

Updated:

Platform:

Replies:

28480 May 3,2005 06:43 AM UTC May 3,2005 04:34 PM UTC Windows Forms 3
loading
Tags: GridControl
mallik
Asked On May 3, 2005 06:43 AM UTC

Hi, Is there any way to get new cell value from griddatabound grid after shorting the data in one the column. I need to get the cell value after shorting the data in the column. MALLIK

Administrator [Syncfusion]
Replied On May 3, 2005 11:55 AM UTC

Exactly how are you trying to look up the data in a sorted grid? Do you know a grid rowindex and grid column index? If so, you can use: object val = this.grid[rowIndex, colIndex].CellValue; to retreive a value from a specific row and column whether or not the grid has been sorted. Do you want to try to retrieve a specific DataRow from the underlying DataTable given that you know a rowindex in a sorted grid? If so, you can use the CurrencyManager to retrieve the DataRow. CurrencyManager cm = this.grid.BindingCOntext[this.grid.DataSource, this.grid.DataMember] as CurrencyManager; DataView dv = cm.List as DataView; int position = this.grid.Binder.RowIndexToPosition(grivenRowIndex); DataRow dr = dv[position].Row;

Administrator [Syncfusion]
Replied On May 3, 2005 04:04 PM UTC

HI, I loaded data into GridDataBoundGrid from a datatable. After that I sorted the GridDataBoundGrid data based on any one of the column data. Then I need to get all rows of data in the sorting order. I try to get data after sorting using DataView, but the data in the rows are same as like data without sorting order. Here i am using the Row Index same as before sorting. Can you give some sample code for this. Mallik >Hi, > >Is there any way to get new cell value from griddatabound grid after shorting the data in one the column. >I need to get the cell value after shorting the data in the column. > >MALLIK >

Administrator [Syncfusion]
Replied On May 3, 2005 04:34 PM UTC

>>I try to get data after sorting using DataView, Do you get the DataView using the code I posted above? Here is a little sample with 2 buttons that output the data in the grid in grid order whether or not it is sorted. One button uses the currencymanager and the other just loops through the grid. http://www.syncfusion.com/Support/user/uploads/GDBG_Sorted_6fb3f071.zip

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

;