I am converting Infragistics 2010 v2 CLR3.5 to Infragistics 2014 v2 using 4.5 CLR using Visual Studio 2013 Professional Update 4. I am getting following error while building the project. Please reply immediately..........Try to give solution of below code of using alternative of Levels instead of changing whole functionality. Let me know the alternative of using "Levels" in the existing code plzzzz.
Below error is there while trying to load to get MenuList where "UltraWebTree" being used previously. Now I am upgrading to "WebDataTree" to get functionality, due to which in WebDataTree1 - related to Levels the error is coming:
Error 324 'Infragistics.Web.UI.NavigationControls.WebDataTree' does not contain a definition for 'Levels' and no extension method 'Levels' accepting a first argument of type 'Infragistics.Web.UI.NavigationControls.WebDataTree' could be found (are you missing a using directive or an assembly reference?)
Code is given below:
menuDS.Tables.Add(mnu3Table); menuDS.Tables.Add(mnu2Table); menuDS.Tables.Add(mnu1Table); UltraWebTree1.Levels[0].ColumnName = "Menu2_Nm"; //WebDataTree1.Nodes[0].Levels[0].ColumnName = "Menu2_Nm"; see this it is not taking Levels of above line, here i need alternative as I can't change code
WebDataTree1.Levels[0].LevelKeyField = "Menu2_ItemID"; if (menuDS.Tables["Menu3"].Rows.Count > 0) { menuDS.Relations.Add("MenuLevel1", menuDS.Tables["Menu2"].Columns["Menu2_ID"], menuDS.Tables["Menu3"].Columns["Menu3_parentID"]); WebDataTree1.Levels[0].RelationName = "MenuLevel1"; //here also same error coming WebDataTree1.Levels[1].ColumnName = "Menu3_Nm"; //here also same error coming WebDataTree1.Levels[1].LevelKeyField = "Menu3_ItemID"; //here also same error coming } if (menuDS.Tables["Menu4"].Rows.Count > 0) { menuDS.Relations.Add("MenuLevel2", menuDS.Tables["Menu3"].Columns["Menu3_ID"], menuDS.Tables["Menu4"].Columns["Menu4_parentID"]); WebDataTree1.Levels[1].RelationName = "MenuLevel2"; WebDataTree1.Levels[2].ColumnName = "Menu4_Nm"; WebDataTree1.Levels[2].LevelKeyField = "Menu4_ItemID"; } WebDataTree1.DataSource = menuDS; WebDataTree1.DataMember = "Menu2"; WebDataTree1.DataBind(); } }
Hello,
The WebDataTree uses bindings and collections of nodes, these topics can help you our as there are also data source options available:
http://help.infragistics.com/Doc/ASPNET/2014.2/?page=WebDataTree_Binding_to_Data.html [edited]
The smart tag designer can be very helpful too.
Full API listing: http://help.infragistics.com/Doc/ASPNET/2014.2/?page=WebDataTree_API_Overview.html
There are also online samples: http://ko.infragistics.com/samples/aspnet/data-tree/data-binding
Let me know if you need further assistance.
Regards,
Damyan Petev
Associate Software Developer
Infragistics, Inc.
I went through the links provided by you. But I am not able to identify an alternative for "Levels" in the following code:
WebDataTree1. Levels[0].RelationName = "MenuLevel1"; WebDataTree1.Levels[1].ColumnName = "Menu3_Nm"; WebDataTree1.Levels[1].LevelKeyField = "Menu3_ItemID";
Please suggest me the solution for this.......!!