Hi,
Yeah, it took me several days to figure this out.
In your web.config file this is what you need to add under the <system.web> tag:
<system.web>
<siteMap defaultProvider="AspNetXmlSiteMapProvider">
<providers>
<add name="TopXmlSiteMapProvider" type="System.Web.XmlSiteMapProvider"siteMapFile="TopNavigationBar.sitemap" />
<add name="LeftXmlSiteMapProvider"type="System.Web.XmlSiteMapProvider" siteMapFile="LeftNavigationBar.sitemap" />
</providers>
</siteMap>
defaultProvider="AspNetXmlSiteMapProvider" specifies your default web.sitemap file.
In my case, I added two additional providers:
<add name="TopXmlSiteMapProvider" type="System.Web.XmlSiteMapProvider"siteMapFile="TopNavigationBar.sitemap" />
&
<add name="LeftXmlSiteMapProvider"type="System.Web.XmlSiteMapProvider" siteMapFile="LeftNavigationBar.sitemap" />
So, in whenever you add your control you will want to reference the provider used in your web.config file like so:
<asp:SiteMapDataSource ID="SiteMapDataSource1" runat="server" SiteMapProvider="LeftXmlSiteMapProvider" ShowStartingNode="False" />
Notice: SiteMapProvider="LeftXmlSiteMapProvider"
This is the name of the provider you specify in the web.config file
Obviously you can change the names accordingly to suit your needs.
Hope this helps.
Regards,
-D-