Hello,
I don't manage to display the title attribute on links. Here is my html code:
and my server code:
Thanks for your answers
I don't manage to display the title attribute on links. Here is my html code:
<
telerik:RadSiteMap
runat
=
"server"
ID
=
"RadSiteMap1"
DataSourceID
=
"SqlDataSource1"
DataFieldID
=
"SiteMapId"
OnNodeDataBound
=
"RadSiteMap1_NodeDataBound"
DataFieldParentID
=
"ParentID"
DataNavigateUrlField
=
"NavigateUrl"
DataTextField
=
"SiteMapTitle"
ShowNodeLines
=
"false"
>
<
DataBindings
>
<
telerik:RadSiteMapNodeBinding
NavigateUrlField
=
"NavigateUrl"
/>
</
DataBindings
>
<
LevelSettings
>
<
telerik:SiteMapLevelSetting
Level
=
"0"
>
<
ListLayout
RepeatColumns
=
"2"
AlignRows
=
"true"
/>
</
telerik:SiteMapLevelSetting
>
</
LevelSettings
>
</
telerik:RadSiteMap
>
<
asp:SqlDataSource
runat
=
"server"
ID
=
"SqlDataSource1"
ConnectionString="<%$ ConnectionStrings:DefaultConnection %>"
SelectCommand="SELECT SiteMapId, ParentID, SiteMapTitle, NavigateUrl, SortOrder, SiteMapTitle as Tooltip FROM [SiteMap]">
<
SelectParameters
>
<
asp:Parameter
DefaultValue
=
"1"
Name
=
"SiteMapId"
Type
=
"Int32"
/>
</
SelectParameters
>
</
asp:SqlDataSource
>
and my server code:
protected
void
RadSiteMap1_NodeDataBound(
object
sender, RadSiteMapNodeEventArgs e)
{
DataRowView nodeData = e.Node.DataItem
as
DataRowView;
e.Node.Target =
"_self"
;
e.Node.ToolTip = nodeData[
"Tooltip"
].ToString(); ;
}
Thanks for your answers