Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# XML .NET
I am using a drop-down menu populated by a sitemap in my project.
All of the menu works correctly, except for the last node! It shows the first two items, and then the rest are 'compressed' so that you may not see the items, but if clicked on, it links correctly to external links.
Can you help?
Here is the sitemap:
<?xml version="1.0" encoding="utf-8" ?>
<siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" enableLocalization="true" >
  <siteMapNode title="" description="">
    <siteMapNode title="Home"   description="Contains Home Page" url="~/Default.aspx">  </siteMapNode>
    <siteMapNode  title="Options"  description="">
      <siteMapNode url="~/AL.aspx" title="AL"  description="" ></siteMapNode>
      <siteMapNode url="~/RC.aspx" title="RC"  description="" ></siteMapNode>
      <siteMapNode url="~/NC.aspx" title="NC"  description="" ></siteMapNode>
    </siteMapNode>
    <siteMapNode title="Services"  description="">
      <siteMapNode url="~/FP.aspx" title="FP"  description="" ></siteMapNode>
      <siteMapNode url="~/WhatToExpect.aspx" title="What to expect"  description="" ></siteMapNode>
    </siteMapNode>
    <siteMapNode url="Calendar.aspx" title="Calendar"  description="" ></siteMapNode>
    <siteMapNode title="About Us"  description="">
      <siteMapNode url="~/ContactUs.aspx" title="Contact Us"  description="" ></siteMapNode>
      <siteMapNode url="~/Directions.aspx" title="Directions"  description="" ></siteMapNode>
      <siteMapNode url="~/SB.aspx" title=" S"  description=""></siteMapNode>
      <siteMapNode url="~/BMF.aspx" title="B "  description=""></siteMapNode>
      <siteMapNode url="~/EO.aspx" title="EO"  description="" ></siteMapNode>
      <siteMapNode url="~/H.aspx" title="H"  description="" ></siteMapNode>
    </siteMapNode> 
    <siteMapNode title="CR" description="">
        <siteMapNode url="link1" title="FCBC"  description="" ></siteMapNode>
        <siteMapNode url="link2" title="ES"  description="" ></siteMapNode>
        <siteMapNode url="link3" description="LSC"></siteMapNode>
        <siteMapNode url="link4" description=""></siteMapNode>
        <siteMapNode url="link5" description="FVP"></siteMapNode>
        <siteMapNode url="link6" description="FLHTS"></siteMapNode>
        <siteMapNode url="link7" description="EZ"></siteMapNode>
        <siteMapNode url="link8" description="Ogs"></siteMapNode>
        <siteMapNode url="link9" description="BPS"></siteMapNode>
      </siteMapNode>
  </siteMapNode>
</siteMap>
and here is the code in the sitemaster that creates menu:
 <div class="menu">
<asp:Menu ID="MainMenu" runat="server" Orientation="Horizontal"
   DataSourceID="SiteMapDataSource1"
   DynamicEnableDefaultPopOutImage="False" SkipLinkText=""  
   StaticEnableDefaultPopOutImage="False"
   Height="300px" IncludeStyleBlock="False" MaximumDynamicDisplayLevels="15" 
   DynamicMenuStyle-Height="150px">
<StaticMenuItemStyle HorizontalPadding="5px" VerticalPadding="2px" />
<StaticHoverStyle BackColor="White" ForeColor="Black" />
<DynamicHoverStyle BackColor="White" ForeColor="Black" />
<DynamicMenuItemStyle ItemSpacing="2px" HorizontalPadding="5px"  
     VerticalPadding="2px" />
</asp:Menu<asp:SiteMapDataSource ID="SiteMapDataSource1"  runat="server" 
         ShowStartingNode="false" />
</div>
The only thing I found different in node with link3 is that it has some dashes in the link...could that be it? Nope...I tried moving the node that doesn't have any subnodes, that didn't work. Tried revising the node whose URL has a dash...that didn't work. It is NOT due to Javascript.
Posted 13-Nov-12 17:41pm
Edited 19-Nov-12 14:47pm
v6
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Check your css or js code if u using in this page....suppose u didn't use those codes means...check all link property are visible true or not....
 
Again u getting this prob's means Better u Delete that last node...and Re-insert again...May be it ll works correctly...
 
Thank u Smile | :)
Happy CodingSmile | :) Smile | :)
  Permalink  
v2
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

there is NO TITLE parameter to display in link 3-9! OOOPs! sorry for wasting time.
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 535
1 CPallini 450
2 OriginalGriff 270
3 George Jonsson 256
4 Suvabrata Roy 229
0 OriginalGriff 4,873
1 CPallini 3,900
2 Sergey Alexandrovich Kryukov 3,474
3 George Jonsson 2,646
4 Gihan Liyanage 2,236


Advertise | Privacy | Mobile
Web01 | 2.8.140905.1 | Last Updated 20 Nov 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100