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. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

UNIQUE COLUMN IN GRID HIDE BUT GET THE VALUE

Thread ID:

Created:

Updated:

Platform:

Replies:

146076 Jul 18,2019 05:17 PM UTC Jul 22,2019 08:49 AM UTC WinForms 3
loading
Tags: SfDataGrid
Deepak
Asked On July 18, 2019 05:17 PM UTC

Dear Sir,

In My Table I have one field as unique like GUID, but in SFDATAGRID I have excluded this column.

In My SFDATAGRID I have records as per below

ID NAME
1 AAAA
1 BBBB

In the Database actually ID record 1 has GUID 500xxxxxxxx, and second 1 has GUID 6660xxxxxxxxxxxxxxxxx, as GUID was unable to show in GRID.

Now, How Can I Get the GUID Value for First Record and second record, on based of GUID will get the form details for update ?

Please reply me at the earliest.

Thanks
Deepak

Farjana Parveen Ayubb [Syncfusion]
Replied On July 19, 2019 10:16 AM UTC

Hi Deepak, 
 
Thank you for using Syncfusion controls. 
 
We have analyzed your query, you can get the value of the data which is exclude from the SfDataGrid by using SfDataGrid.View.Records. Otherwise get the value from SfDataGrid.DataSource.  
 
Please refer the below code example 
 
// Get the value by using sfDataGrid.View.Records 
var value = (sfDataGrid.View.Records[0].Data as DataRowView).Row.ItemArray[0]; 
 
//Get the value by using DataSource  
var value1 =((sfDataGrid.DataSource as DataTable).Rows[0] as System.Data.DataRow).ItemArray[0]; 
 
 
Regards, 
Farjana Parveen A 


Deepak
Replied On July 19, 2019 04:53 PM UTC

Hi Farjana Parveen A,

Thanks for Your Reply.

Our Issue is Resolved.

Once Again Thanks for Fast Reply as well as thanks for our important issue resolved.

Thanks
Deepak

Farjana Parveen Ayubb [Syncfusion]
Replied On July 22, 2019 08:49 AM UTC

Hi Deepak, 
 
Thanks for the update. 
 
We are glad to know that the reported problem has been resolved at your end. Please let us know if you have any further queries on this. We are happy to help you. 
 
Regards, 
Farjana Parveen A 


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

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

Live Chat Icon For mobile
Live Chat Icon