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.

Binding Combobox contents within a GridDataControl

Thread ID:

Created:

Updated:

Platform:

Replies:

96493 Sep 16,2010 08:30 AM Oct 12,2010 06:16 AM Silverlight 2
loading
Tags: GridControl
Trevor Tickner
Asked On September 16, 2010 08:30 AM

Hi,

I'm busy evaluation your data grid.
I've noticed all your ComboBox-in-cell examples bind the combobox contents to a static resource:

E.g.


How would one bind the combobox contents (ItemsSource) to a (ObservableCollection) property on the data model assigned to the page.

E.g. (pseudo code)

class MyModel
{
List ItemsInGrid;
List LookupItemList;
}

in page code-behind, constructor:
{
DataContext = new MyModel();
}

in XAML, within GridDataControl, CellEditItemTemplate containing Combobox:




i.e. how do I bind to my DataContext.LookupItemList list?




Pavel
Replied On September 29, 2010 07:36 AM

Give some x:Name to your page (i use cotrolRoot everywhere for this)

Then just use ElementName binding:






Jeraldes J [Syncfusion]
Replied On October 12, 2010 06:16 AM

Hi,

Sorry for the delay caused.

Hi Pavel thanks for your update regarding this answer you provided.

Let us know if you need any other details.

Regards,
Jeraldes J



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.

;