Welcome to the Xceed Community Sign in | Join | Help
Community Search  

Re: How to insert a Listbox inside a grid cell with xml binding

  •  04-30-2008, 6:24 PM

    Re: How to insert a Listbox inside a grid cell with xml binding

    XML data is currently not 100% supported by the grid. That said, you could refer to this thread to get an idea of how to proceed.

    As for display the values of 2 subnodes in a cell, I suggest you create a new DataTemplate that consists of a Panel and 2 TextBlocks whose Text properties are bound to the n and v nodes. This template should then be provided to the column's CellContentTemplate property. Something like:

    <xcdg:DataGridControl.Columns>
       <xcdg:Column FieldName="p">
          <xcdg:Column.CellContentTemplate>
             <DataTemplate>
                <StackPanel>
                   <TextBlock Text="{Binding Path=n}"/>
                   <TextBlock Text="{Binding Path=p}"/>
                </StackPanel>
             </DataTemplate>
          </xcdg:Column.CellContentTemplate>
       </xcdg:Column>
    </xcdg:DataGridControl.Columns>

    Of course this assumes that you implemented the details in the first thread regarding XmlDataGridItemProperty objects. 


    Technical Writer - Xceed Software

    Of all the things I've lost, I miss my mind the most. - Mark Twain
    Filed under: ,
View Complete Thread
Contact | Site Map | Reviews | Legal Terms of Use | Trademarks | Privacy Statement Copyright 2008 Xceed Software Inc.