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
135
Bind a single node's child collection to a datatable
posted

Hi,

I'm trying to create a tree manually with various nodes lower down in the tree binding to different datasources. The node configured to a specific datasource must pull the column layout from the datasource.

Hope this ilustration describe the requirement.

A (manual)

|----B (Manual)

     |------C (bound to datasource)

            Column A | Column B | Column C

            Rows()

     |------D (Manual)

            |-------E (Bound to another datasource)

                    Column F | Column G

                    Rows()

Can this also be configured via XML? Can I describe which nodes should be bound to a datasource and which member?

Cheers

  • 469350
    Verified Answer
    Offline posted

     

    francoisw said:
    Can this also be configured via XML?

        Hm, I'm not sure exactly what you mean, but I would say no. The tree doesn't deal with XML in any way. You might be able to load a data source (like a datatable) from XML, but that has nothing to do with the tree.

        You could acheive what you want by jus adding the unbound nodes to the tree and then calling SetDataBinding on the nodes collection where you want the bound data. Or you could create a data structure of some sort that has all of these nodes and bind that the to the tree.