Welcome to Office and SharePoint Pro Sign in | Join | Help
in Search

SUBSCRIBE to Windows IT Pro Magazine & SAVE 30%      FREE Email Newsletters Vista UPDATE, Windows IT Pro UPDATE & More

location of QuickLaunch contents/attributes

Last post 06-04-2007, 8:02 PM by jherschel7. 1 replies.
Sort Posts: Previous Next
  •  06-04-2007, 8:02 PM 28407

    location of QuickLaunch contents/attributes

    I would like the QuickLaunch to be collapsible/expandable.  Unfortunately, this cannot be done (tried to modify to treeview per ms website, but no luck).  

    When a person selects, SITE SETTINGS-> MODIFY SITE SETTINGS->NAVIGATION, he/she can customize the QuickLaunch and move links up/down, add, delete, hide, etc..

    Where is this 'setting' stored?  In the SQL database?

    I would like to create a web part that grabs this info and creates a quicklaunch that is expandable / collapsible

    Example
    [+] Documents
       - Shared Docs
       - Doc lib 2
    [-] Lists
    [-] Discussions
    [+] Sites
      - Site 1
      - Area 51
      - Site 3
    [-] People and Groups

    Thanks,
    Jon Herschel
  •  06-06-2007, 7:32 AM 28408 in reply to 28407

    location of QuickLaunch contents/attributes

    I figured it out (thanks to a friend of a friend, Ben) and in case some of you would benefit, here it its...

    SPSite site = SPControl.GetContextSite(Context);

    SPWeb web = site.OpenWeb();

    SPNavigationNodeCollection nodes = web.Navigation.QuickLaunch;

    foreach (SPNavigationNode node in nodes)

    {

    // Get Children if any

    SPNavigationNodeCollection Children = node.Children;

    if (Children.Count != 0)

    {

    if (node.IsVisible == true) // only display if visible & isExternal is set to true

    {

    writer.Write("<a href='" + node.url + "'>" + node.title + "<a/><br />");

    foreach (SPNavigationNode child in Children)

    {

    if (child.IsVisible == true) // only display if set to true

    {

    writer.Write("<a href=\"" + child.Url + "\">" + child.Title + "</a><br />");

    }

    }

    }

    }

    }

     

    Regards,

    Jonathan Herschel

    Anexinet

View as RSS news feed in XML
SPONSORED LINKS FEATURED LINKS

Extend SharePoint to the ExtranetView this web seminar to learn how SharePoint administrators can improve partnering and collaboration effectiveness. Order Your Fundamentals CD Today!Get up to speed quickly and learn how to uncover rich information management capabilities with this free SharePoint CD. Keep Project Teams on TrackProtect you project team productivity by keeping SharePoint running. Download this white paper to learn about Continuous Data Protection for SharePoint. Leverage Hosted Exchange and SharePoint See how a business of any size can strategically acquire the messaging and collaboration infrastructure of a Fortune 50 enterprise. Top Factors in a Successful Disaster Recovery PlanAre you gambling with disaster? Chances are, you won't ever experience a Level Four disaster, but even the smaller-scale disasters can paralyze business operations unless you've developed a plan for rapidly restoring IT services. The Essential Guide to Fax Server SoftwareThis fundamentals eBook will introduce you to the IT benefits of fax servers. Learn how you can better serve your company’s customers while still implementing a solution that is easy to support, secure, and integrate. Maximize your SharePoint InvestmentLive, in-person training on how to architect and administer the optimal SharePoint infrastructure. Take advantage of Early Bird pricing - $99! Find a new job on the all new IT Job Hound!Search jobs, post your resume, and set up job e-mail alerts! Get Specialized SharePoint Training!SharePoint MVPs Dan Holme, Michael Noel, and Andrew Connell share their perspective and expertise in these exclusive eLearning seminars. One Event for developers and one for IT pros. Choose the one that fits your needs! Top 5 SharePoint Migration StrategiesAchieve stress-free content and user migration to an online collaboration platform! View this on-demand seminar to learn how. Access Expert SharePoint Solutions for only $5.95!With the online Monthly Pass, you can have all the SharePoint solutions in Windows IT Pro right at your fingertips, including access to the more than 10,000 articles in our content archives! You'll also receive a full digital copy of the latest issue of W Leverage Your SharePoint InvestmentAre you losing productivity or profit due to poor document management processes? View this seminar to learn how MOSS can help.