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.

Indexers in Mapping Names?

Thread ID:

Created:

Updated:

Platform:

Replies:

106438 Jan 7,2013 11:25 AM May 19,2014 07:53 AM WPF 8
loading
Tags: GridDataControl
Will Rogers
Asked On January 7, 2013 11:25 AM

Quick question: can I use an indexer in the MappingName property text of a GridDataVisibleColumn? I can get the code to compile and run, and the Visible column is added to the GridDataControl, but there seems to be an issue with the binding at the moment. I just want to know if this is possible so I don't waste time seeking a solution if one doesn't exist.

Example: 

OrderGridDataControl.VisibleColumns.Add(new GridDataVisibleColumn() { HeaderText = "Unit Cost", MappingName = "Unit[0].Cost" });

Thanks in advance,

Will.



Kannan R [Syncfusion]
Replied On January 22, 2013 01:04 AM

Hi Will,

 

Thanks for using Syncfusion products.

 

We have analyzed your query with our sample and please find our response below.

 

We can use an indexer in the MappingName property text of a GridDataVisibleColumn, and for this we need to set VisibleColumnType and Binding property for the particular column. We have prepared sample based on your requirement and it can be downloaded from below location.

 

Sample Location: MappingName.zip

 

Please let us know if you have any queries.

 

Thanks,

Kannan.R


Will Rogers
Replied On January 23, 2013 08:19 AM

This worked. I was previously unaware you could set a Binding in addition to a MappingName on a column. The samples and documentation led me to believe databinding was solely performed through the MappingName property.

Thanks,
Will.

Kannan R [Syncfusion]
Replied On January 24, 2013 12:45 AM

Hi Will,

 

Thanks for your valuable feedback, please let us know if you need any assistance in future.

 

Thanks,

Kannan.R


Rainer Worbis
Replied On December 18, 2013 05:19 AM

Hello,
unfortunately i can't access the sample (get some "AccessDenied" XML back). Can you please make the sample public?
Best regards,
Rainer Worbis

Saravanan M [Syncfusion]
Replied On January 6, 2014 07:37 AM

Hi Rainer,

Sorry for the inconvenienced,

Due to our server failure we lost previous data. We have prepared a sample based on you requirement and you can download it from the below location.

Sample Location: GridDataControlSample_Mappingname.zip

Please let us know if this solution helps you,

Regards,

Saravanan.M


Eric Gurney
Replied On March 25, 2014 02:52 PM

this sample doesn't seem to show the use of an indexer...
Can you please post a solution that does?

Thanks,
Eric


Michael Cheng
Replied On April 11, 2014 08:58 AM

The sample that can be downloaded doesn't show the solution.

Farjana Parveen Ayubb [Syncfusion]
Replied On May 19, 2014 07:53 AM

Hi Michael,

Sorry about the inconvenienced, 

We have prepared a sample by using indexer for both SfDataGrid and GridDataControl and you can download it from the following location

Regards,

Farjana Parveen A

 


Attachment: Mapping_Name_Sample_for_SF_and_GDC_2b54fad9.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.

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.

;