Hi,
As a newbie I'm having trouble getting started with the site map control. Just as a working example for myself, I tried to setup an ultra simple breadcrumb but I failed so I need some help. My page looks like this:
The table (tbl_SiteMap) in my data source looks like this:
NodeNo ParentNodeNo NodeText NodeURL
1 0 MainMenu user/MainMenu.aspx
2 1 Logbook user/Logbook.aspx
When I run the page, I get this error: "This constraint cannot be enabled as not all values have corresponding parent values."
I've only got two nodes, they both have an entry for Parent Node so I can't tell what the problem is. Can you help?
Regards
Geoff
As a newbie I'm having trouble getting started with the site map control. Just as a working example for myself, I tried to setup an ultra simple breadcrumb but I failed so I need some help. My page looks like this:
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="user_Default" %>
<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<
html
xmlns
=
"http://www.w3.org/1999/xhtml"
>
<
head
runat
=
"server"
>
<
title
></
title
>
</
head
>
<
body
>
<
form
id
=
"form1"
runat
=
"server"
>
<
telerik:RadScriptManager
ID
=
"RadScriptManager1"
runat
=
"server"
></
telerik:RadScriptManager
>
<
telerik:RadFormDecorator
ID
=
"FormDecorator1"
runat
=
"server"
DecoratedControls
=
"all"
DecorationZoneID
=
"rfd-demo-zone"
></
telerik:RadFormDecorator
>
<
div
>
<
telerik:RadSiteMap
runat
=
"server"
ID
=
"RadSiteMap1"
DataSourceID
=
"SqlDataSource1"
DataFieldID
=
"NodeNo"
DataFieldParentID
=
"ParentNodeNo"
DataTextField
=
"NodeText"
DataNavigateUrlField
=
"NodeURL"
>
<
DefaultLevelSettings
ListLayout-RepeatDirection
=
"Horizontal"
SeparatorText
=
"/"
Layout
=
"Flow"
/>
</
telerik:RadSiteMap
>
<
asp:SqlDataSource
runat
=
"server"
ID
=
"SqlDataSource1"
ConnectionString="<%$ ConnectionStrings:RAMtrack %>"
ProviderName="<%$ ConnectionStrings:RAMtrack.ProviderName %>"
SelectCommand="SELECT NodeNo, ParentNodeNo, NodeText, NodeURL FROM tbl_SiteMap">
</
asp:SqlDataSource
>
</
div
>
</
form
>
</
body
>
</
html
>
The table (tbl_SiteMap) in my data source looks like this:
NodeNo ParentNodeNo NodeText NodeURL
1 0 MainMenu user/MainMenu.aspx
2 1 Logbook user/Logbook.aspx
When I run the page, I get this error: "This constraint cannot be enabled as not all values have corresponding parent values."
I've only got two nodes, they both have an entry for Parent Node so I can't tell what the problem is. Can you help?
Regards
Geoff