C1SiteMapDataSource Features > Add a SiteMap File |
You can populate the C1SiteMapDataSource control by adding a SiteMap file to it.
Complete the following steps to add a .sitemap file to the C1SiteMapDataSource control.
Set the SiteMapFile property in the <cc1:C1SiteMapDataSource />
tag, to add a .sitemap file in Source View.
Copy Code
|
|
---|---|
<cc1:C1SiteMapDataSource ID="C1SiteMapDataSource1" runat="server" SiteMapFile="~/web1.sitemap" /> |
Add the following code to the Page_Load event, to add a .sitemap file to the C1SiteMapDataSourceControl.
To write code in C#
C1SiteMapDataSource1.SiteMapFile = "web1.sitemap";
To write code In Visual Basic
C1SiteMapDataSource1.SiteMapFile = "web1.sitemap"