×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Navigation Menu 'Empty' Node

Navigation Menu 'Empty' Node

Navigation Menu 'Empty' Node

(OP)
I am using Visual Studio 2010 VB.Net.
I have added a naviation menu to my site master page.
It has a horizontal orientation.
I have pointed the navigation Menu at an XML data source of menu items which works except that the far left shows an 'empty' option. When running the project it looks like a blank option.

Opening the Navigation control control up in design mode by selecting 'Edit Menu Items' shows two entries in the 'Available data bindings:' list.
The node first is '(Empty)' and the second is 'SiteMapNode'. The '(Empty)' one is causing my problem and I can't find a way to remove it so the navigation control is only set from the XML SiteMapNode.

Can anybody point me in the right direction on how to remove the '(Empty)' node?


Dazed and confused.

Remember.. 'Depression is just anger without enthusiasum'.

RE: Navigation Menu 'Empty' Node

(OP)
Wierd. Solved it.

I spent ages trying to solve this on Friday and as soon as I post the question the penny drops and I figure it out.
My XML Site Map source was defined incorrectly.

How it was with the error - the top level node was of course empty

CODE

<siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" >

  <siteMapNode>

  <siteMapNode url="" title="Options Sub-Menu 1"  description="Options Sub-Menu 1">
      <siteMapNode url="" title="Option 1"  description="Option 1" >
      </siteMapNode>

      <siteMapNode url="" title="Option 2"  description="Option 2" >
      </siteMapNode>
 </siteMapNode>


    <siteMapNode url="" title="Options Sub-Menu 2"  description="Options Sub-Menu 2">
      <siteMapNode url="" title="Option 1"  description="Option 1" >
      </siteMapNode>

      <siteMapNode url="" title="Option 2"  description="Option 2" >
      </siteMapNode>
    </siteMapNode>

</siteMapNode>
    
    
</siteMap> 

How it is after correction - the top level node now has a value

CODE

<siteMap xmlns="http://schemas.microsoft.com/AspNet/SiteMap-File-1.0" >

  <siteMapNode url="" title="Home" description ="Home">

  <siteMapNode url="" title="Options Sub-Menu 1"  description="Options Sub-Menu 1">
      <siteMapNode url="" title="Option 1"  description="Option 1" >
      </siteMapNode>

      <siteMapNode url="" title="Option 2"  description="Option 2" >
      </siteMapNode>
 </siteMapNode>


    <siteMapNode url="" title="Options Sub-Menu 2"  description="Options Sub-Menu 2">
      <siteMapNode url="" title="Option 1"  description="Option 1" >
      </siteMapNode>

      <siteMapNode url="" title="Option 2"  description="Option 2" >
      </siteMapNode>
    </siteMapNode>

</siteMapNode>
    
    
</siteMap> 

Dazed and confused.

Remember.. 'Depression is just anger without enthusiasum'.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login


Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close