It's strange, I have tested it following your method, and I didn't find any error. I placed the menu either into Master or into a single page, either set the menuItems manually or bind them from sitemap, no issue occured. So I guess if is elsewhere cause the issue? I paste my code as below to hope it could be helpful to you. Thank you!
masterPage.
1 <%@ Master Language="C#" AutoEventWireup="true" CodeFile="MenuTest.master.cs" Inherits="MenuTest" %>
2
3 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
4
5 <html xmlns="http://www.w3.org/1999/xhtml" >
6 <head runat="server">
7 <title>Untitled Page</title>
8 </head>
9 <body>
10 <form id="form1" runat="server">
11 <div>
12 <asp:Menu ID="Menu1" runat="server" DataSourceID="SiteMapDataSource1" Orientation="Horizontal"
13 StaticDisplayLevels="2">
14 </asp:Menu>
15 <asp:SiteMapDataSource ID="SiteMapDataSource1" runat="server" />
16 <br />
17 <asp:contentplaceholder id="ContentPlaceHolder1" runat="server">
18 </asp:contentplaceholder>
19 <br />
20 </div>
21 </form>
22 </body>
23 </html>
MenuTest3.aspx:
1 <%@ Page Language="C#" MasterPageFile="~/MenuTest.master" AutoEventWireup="true" CodeFile="MenuTest3.aspx.cs" Inherits="MenuTest3" Title="Untitled Page" %>
2 <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
3 <br />
4
5 ...
6
7 <br />
8 <asp:Image ID="Image1" runat="server" ImageUrl="~/images/WalkThru/KitReadmeFile.gif" /><br />
9 <br />
10
11 ....
12
13 <br />
14 <asp:Image ID="Image2" runat="server" ImageUrl="~/images/WalkThru/KitReadmeFile.gif" /><br />
15 <br />
16 <a name="anchor1">anchor one</a>
17 <br />
18
19 ...
20
21 <br />
22 <br />
23 <a name="anchor2">anchor two</a><br />
24 <br />
25
26 ....
27
28 <br />
29 <br />
30 <a name="anchor3">anchor three</a>
31 </asp:Content>
MenuTest4.aspx:
1 <%@ Page Language="C#" MasterPageFile="~/MenuTest.master" AutoEventWireup="true" CodeFile="MenuTest4.aspx.cs" Inherits="MenuTest3" Title="Untitled Page" %>
2 <asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">
3 <br />
4
5 ...
6
7 <br />
8 <asp:Image ID="Image1" runat="server" ImageUrl="~/images/WalkThru/KitReadmeFile.gif" /><br />
9 <br />
10
11 ....
12
13 <br />
14 <asp:Image ID="Image2" runat="server" ImageUrl="~/images/WalkThru/KitReadmeFile.gif" /><br />
15 <br />
16 <a name="anchor1">anchor one</a>
17 <br />
18
19 ...
20
21 <br />
22 <br />
23 <a name="anchor2">anchor two</a><br />
24 <br />
25
26 ....
27
28 <br />
29 <br />
30 <a name="anchor3">anchor three</a>
31 </asp:Content>
Johnson