.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Central SiteMap to drive TopNav

Posted By:      Posted Date: September 22, 2010    Points: 0   Category :SharePoint


I am pulling my hair out trying to figure out why I can't my sitemap datasource to work.  It only works at the root level of my web app site collection.  As soon as I go to another site collection, the navigation is appended with /sites/[current site].

Here is my entry in my web config:

<add name="DemoGlobalNavSiteMapProvider" siteMapFile="/_layouts/1033/styles/demo/DemoGlobalNav.sitemap" type="Microsoft.SharePoint.Navigation.SPXmlContentMapProvider, Microsoft.SharePoint, Version=, Culture=neutral, PublicKeyToken=71e9bce111e9429c" />

Here is my asp:menu / datasource script:

   CssClass="s4-tn" /> 
  <asp:SiteMapDataSource runat="server" ID="SiteMapDataSource1"/>
  <SharePoint:DelegateControl runat="server" ControlId="CustomXmlContentMapProvide" Id="DemoGlobalNavDelegate"> 

View Complete Post

More Related Resource Links

Custom Control Design-Time SiteMap Provider Error


Greetings - I was referred here by MSDN forums hope this is the right place -  

I have a custom control (:WebControl) that renders web.sitemap in a specific way. While it runs error free and produces the expected result, at Design-Time it complains

Error Creating Control - MyControl  The provider 'AspNetXmlSiteMapProvider' specified for the defaultProvider does not exist in the providers collection.

I have discovered that the error is cause by this line of code:

string div = string.Format("<div class='{0}' id='{1}'>{2}</div>", this.CssClass, this.ID.ToString(), EnumerateNodesRecursive(SiteMap.RootNode, level));

or more specifically, by the reference to SiteMap.RootNode - I am not clear what is missing thoough because I have configured the SiteMapProvider in web.config as this:

        <add name="AspNetXmlSiteMapProvider" 
             type="System.Web.XmlSiteMapProvider, System.Web, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" 

ClickOnce: Deploy and Update Your Smart Client Projects Using a Central Server


ClickOnce is a new deployment technology that allows users to download and execute Windows-based client applications over the Web, a network share, or from a local disk. Users get the rich interactive and stateful experience of Windows Forms, but still have the ease of deployment and updates available to Web applications. ClickOnce applications can be run offline and support a variety of automatic and manual update scenarios.Learn all about it here.

Brian Noyes

MSDN Magazine May 2004

ImageURL SiteMap Node


Hi Can anyone tell me how i can add the ImageURL from a sitemap into a navigation menu, i had this working with webforms but cannot get it to work with mcv

var sbMenuHelper = new StringBuilder();

sbMenuHelper.Append("<ul class='cssMenu'>");

var topLevelNodes = SiteMap.RootNode.ChildNodes;
foreach (SiteMapNode node in topLevelNodes)
    if (SiteMap.CurrentNode == node)
        sbMenuHelper.AppendFormat("<a href='{0}'>{1}</a>", node.Url, helper.Encode(node.Title));

return sbMenuHelper.ToString();

        description="Contact Us"

Linq Save to ror.xml or other sitemap.xml


Hi there, 

I'm trying to make a script for a site, that updates the sitemaps in the background.

I didn't create this site, and someone before me added in the ror.xml and sitemap.xml and urllist.txt files.

I want to update these all at the same time. If the url is not in there already of course...

<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:ror="http://rorweb.com/0.1/" >
  <title>ROR Sitemap for http://www.envirospec.co.nz/</title>

Turning off Crawling the Central Administration site?



There are 2 places that "Search Visibility" can be set on WSS3 servers:


               Default > Site Settings > Search Visibility


Central Administration > Site Settings > Search Visibility



What are the ramifications of "hiding" the Central Administration site from search?

SharePoint 2007 Central Admin - blank page, isapimodule error in IIS


I've got a Windows 2008 SP2 server runing x64.

When i try to access the SharePoint Central Admin site, I just get a blank page. No errors in the Windows logs, nothing showing up in the SharePoint logs. The IIS log shows a 500 error.

I enabled Failed Request Tracing for the 500 status code, which gives me the following information:

ModuleName IsapiModule

Notification 128

HttpStatus 500

HttpReason Internal Server Error

HttpSubStatus 0

ErrorCode 2147942593


Trying to get to a page via an email link. Could the sitemap be stopping this?


I had this working.  I would email a link to a page (i.e. Work.aspx), and using the code below, the user would be routed to the login page and then sent  to Work.aspx after logging in.

But since I added a site map this isn't working.  I always go directly to my home page.  If I set Work.aspx as my start page in VS it works, but not if I click a link in the email.

Any thoughts?

 protected void Page_Load(object sender, EventArgs e)


        if (!Page.User.Identity.IsAuthenticated)

            Response.Redirect("~/Login.aspx" + "?ReturnUrl=~/Work.aspx");


    protected void Page_Load(object sender, EventArgs e)
        if (!Page.User.Identity.IsAuthenticated)

Word save file on SharePoint via mapped drive


Hi, I have a Document Library mapped to a drive letter. I am able to browse the drive through Windows Explorer. However when I try to save a document to the drive Word returns, 'Unable to connect to the Web server.' .  I have been unable to find any information regarding this error message. If I try to create a document in the Document Library through Windows Explorer and the mapped drive, I get a different error message: 'Unable to create the file 'New Microsoft Office Word Document.docx' There is no user session key for the specified logon session.' After I click OKand refresh the directory, a 0 KB New Microsoft Word Document.docx file has been created. When that file is opened, it is in Read-Only mode.


Windows Server 2003 R2
Webclient service started
Signed into the Microsoft Online Services Sign in Application
IE configured through the sign in application
site added to the trusted sites in IE

Thank you again for your input.

sitemap control user rights enable and disable



iam using masterpage and sitemap in my project, what i want to is that

if user login is did, based on the user previlage in need to show the sitemap menu page

if user i have the previlage to see the page then i should enable that page otherwise

i need disable that page

looking for the valuable suggestions

Why does .NET Framework require 841 MB hard drive space on C:

Just downloaded .NET Framework 4 from Microsoft website. Installation says it requires 841 MB space on my C: drive. Why so much? I am presuming that this is in addition to the space for the other versions of .net installed. This is not going to be installed without a very good reason for this much space required. Can anybody enlighten me on this? Any way to lighten the space requirement load?  

Sitemap issue

Hello, This question pertains to the web.sitemap and the sitemap control. I have the following entry in the web.sitemap:<siteMapNode url="Default.aspx" title="Home" description=""> <siteMapNode url="" title="Articles" description=""> <siteMapNode url="~/TBSArticles/ShowCategories.aspx" title="Categories" description="" /> <siteMapNode url="~/TBSArticles/ProductShowCase.aspx" title="Product Showcase" description="" /> <siteMapNode url="~/TBSArticles/ProductReview.aspx" title="Product Review" description="" /> </siteMapNode> </siteMapNode> </siteMap> The Home and Article texts show as separate tabs on the menu control. Under Article, "Categories", "Product Showcase" and  "Product Review" show as drop down menus. When I click on "Categories" the site map control shows "Home -> Article -> Categories", and the ShowCategories.aspx page is displayed on the browser . The ShowCategories.aspx page has several links. When any one is clicked it it leads to the BrowseArticles.aspx page with an unique querystring value. The problem is that at this stage, the sitemap becomes blank an

How to restore a database to the d drive

I have a 2008 database I need to restore, but my C drive is almost full.  How do I telll it to restore my database to the D drive?  

regasm 4.0 generates error for DLL on a mapped network drive

Calling regasm from .NET Framework 4.0 generates an error for a DLL that is on a mapped network share.  This occurs during our debug builds on developer machines (we actually call a utility that wraps around regasm to perform COM-based registration).  The error is: RegAsm : error RA0000 : Could not load file or assembly 'file:///m:\<file being regasmed>' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515) I can work around this issue by modifying regasm.exe.config to include the loadFromRemoteSources element.  This seems like an annoying change for something that seems like a fairly common task. Is there some better way to enable this? Thanks, -Kevin

Autodelete log files on L: drive

Is there a way to automatically delete sharepoint logs on the server L: drive when space fills up?  I keep getting mom alerts on this drive.

Web Application list in Central Admin in 2007

Can somebody tell me where Central Admin pulls the data for: Central Administration > Application Management > Web Application List   Somehow, the name for one of my applications has changed, but the URL has remained the same.  The website content itself, the website in IIS, and the content database name all still appear to be intact and nothing has changed there.  Everything seems to be fine, I just happened to notice that the NAME of this one web application has changed and it's really bothering me that it could possibly be pointing to the wrong data.  HELP please!

Can Web Services be blocked by Central administration ?

I am a Site Collection administrator. I am thinking of using Web Services (_vti_bin/Lists.asmx etc.,) and display some data regarding Lists, Permissions, SubSites on some pages. My question is whether accessing these web services at site level can be blocked by central administration or not. If they cannot be blocked, then I would like to go forward on what I have mentioned above. Can anyone please clarify. Thanks.
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend