Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
233
Binding problem
posted

 Hi,

I'm using a XamlDataGrid bound to a set of Business Objects, this objects has the following structure:

public class MyObject
{

        private MyObject2 _o2 = new MyObject2();

        public MyObject2 O2
        {
            get
            {
                return _o2;
            }
            set
            {
                _o2 = value;
            }
        }

}

public class MyObject2
    {
        public string Name       

        {
            get;
            set;
        }
    }

Due to some technical requirements the grid datasource is bound to a list of MyObject and i need to display the property Name of the MyObject2 as a column on the grid. So for achieving this I'm using the following XAML code for the field declaration.

                       <igDP:Field Name="O2.Name"
                            ColumnSpan="1"
                            RowSpan="1">
                            <igDP:Field.Label>
                                Name
                            </igDP:Field.Label>
                        </igDP:Field>

 After doing this binding, nothing on the grid is rendered, i think that it crashes. So i will like to know why is this happening, and how can i achieve this type of binding.

After I remove this column, for testing purposes, the grid is rendered, but this message is appearing on the output window of visual studio.

System.Windows.Media.Animation Warning: 6 : Unable to perform action because the specified Storyboard was never applied to this object for interactive control.; Action='Stop'; Storyboard='System.Windows.Media.Animation.Storyboard'; Storyboard.HashCode='36939349'; Storyboard.Type='System.Windows.Media.Animation.Storyboard'; TargetElement='RecordSelector: DataRecord- 1 jjj: xxxxxxx'; TargetElement.HashCode='38118303'; TargetElement.Type='Infragistics.Windows.DataPresenter.RecordSelector'