I am upgrading from Infragistics 10.3 to Infragistics 14.2 controls. The current control I'm trying to upgrade is from a UltraWebTree to a WebDataTree. Previously, the markup looked like such:
<ignav:UltraWebTree ID="tvwVacancy" runat="server"> <AutoPostBackFlags NodeChanged="True" /> <Nodes> <ignav:Node Text="Root"></ignav:Node> </Nodes> <Levels> <ignav:Level Index="0"></ignav:Level> <ignav:Level Index="1"></ignav:Level> </Levels></ignav:UltraWebTree>
So far, all I have is the bare bones of the WebDataTree:
<ignav:WebDataTree ID="wdtVacancy" runat="server"> <AutoPostBackFlags SelectionChanged="On" /> <DataBindings> <ignav:DataTreeNodeBinding DataMember="ReportName" TextField="ReportName" ValueField="ReportName" /> </DataBindings></ignav:WebDataTree>
Right now I am getting an error on the binding:
pCurrentTree.DataSource = dvReportspCurrentTree.DataMember = "ReportName"pCurrentTree.DataBind()
dvReports is a DataView pulled from a DataSet who queries the reports in the database by module (in this example, I'll use Vacancy). This code previously worked fine with the old controls, so I feel I'm not fully understanding how to do the databinding with the new control. I've read a few forum posts on Infragistics' site, and done a few things they've told me (set a PrimaryKey for the DataSet), but they're using the Hierarchical DataSet by Infragistics, I do not need that.
The operation of the tree is that whichever module is selected (a Button above the WebDataTree), that tree is expanded and filled with the Reports that are pulled back in the DataSet for that module. There are eight trees on the page in all.
Unfortunately, I have not found anything on Infragistics' site or elsewhere that shows if this is possible at all, and if so, how to do it. Anyone familiar with this kind of setup? Thanks.
(P.S. I guess the same functionality could be done with a WebDataMenu, so if you have done it with that control, please chime in.)
Hello jbrunskowski,Thank you for sharing this with the community. We believe sharing knowledge will benefit all.
It appears that there were multiple issues with my code. I was trying to use a DataView (as that was the previous code). Once I changed that to a DataSet, then it binded fine. The next issue was that I was giving the ReportName for the DataMember when it should have been Report. I want to leave this up just in case anybody else has similar issues.