When i check the list in debug, it is filled correctly and then it is
Here is the code:
aspx:
<telerik:RadScriptManager ID="RadScriptManager1" runat="server">
</telerik:RadScriptManager>
<div>
<telerik:RadMenu runat="server" ID="CategoriesMenu" Skin="Black"
DataTextField="Title" DataFieldID="Id"
DataSourceID="objectDS" DataFieldParentID="ParentId"
DataNavigateUrlField="Id" DataValueField="Id" AppendDataBoundItems="True">
</telerik:RadMenu>
<asp:GridView runat="server" ID="TestGrid"></asp:GridView>
</div>
<asp:LinqDataSource ID="LinqDataSource1" runat="server"
ContextTypeName="IpitchitWebsiteModel.IpitchitWebsiteModelDataContext"
Select="new (Id, ParentID, Title)" TableName="Categories">
</asp:LinqDataSource>
<asp:ObjectDataSource runat="server" ID="objectDS" SelectMethod="GetTreeByParent"
TypeName="IpitchitWebsiteModel.DataRepository.CategoryRepositoy">
<SelectParameters>
<asp:Parameter Name="id" Type="Int32" DefaultValue="10" />
<asp:Parameter Name="visibility" Type="Int32" DefaultValue="0" />
<asp:Parameter Name="showRootCategory" Type="Boolean" DefaultValue="false" />
</SelectParameters>
</asp:ObjectDataSource>
cs:
[DataObjectMethodAttribute(DataObjectMethodType.Select, true)]
public List<Categories_GetTreeByParentResult> GetTreeByParent(int? id, int visibility, bool showRootCategory)
{
return db.Categories_GetTreeByParent(id, visibility, showRootCategory).ToList();
}
from dbml:
So when i remove parentid parameter DataFieldParentID menu control will work. Otherwise not. This looks to me as bug.