Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET
sir,
 
i have design master page placed menustrip set orientation in horizontal mode but still while view in browser it shows vertical menu can you please help me out my source code is as follows
<asp:ContentPlaceHolder id="head" runat="server">
    
</head>
<body>
    <form id="form1"  runat="server">
    <div align="center">
        style="font-family: 'Arial Narrow'; color: #FF0000; background-color: #FFFF00">My new web site<br />
        <asp:Menu ID="Menu1" runat="server" Orientation="Horizontal" StaticSubMenuIndent="10px">
            <items>
                <asp:MenuItem NavigateUrl="~/Default.aspx" Text="HOME" Value="HOME">
                
                <asp:MenuItem NavigateUrl="~/About.aspx" Text="ABOUT" Value="ABOUT">
                
                <asp:MenuItem NavigateUrl="~/Contact.aspx" Text="CONTACT" Value="CONTACT">
                
                <asp:MenuItem NavigateUrl="~/Change.aspx" Text="CHANGE" Value="CHANGE">
                
            </items>
        
 <asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server">
        
        
    </div>
    </form>
Posted 3-Sep-12 21:53pm
deeptul661
Edited 3-Sep-12 22:08pm
v2
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 4

Use this valuable thread!
 
ASP.NET Horizontal Menu Control[^]
 
regards
Karthik.J
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

you have put your content place holder outside of your form and then close it before you have closed your form
 
try using this code
 
i copied your code and tried to run it but there were issues cos it was very neat
 
<form>
 
 <asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server">
     <asp:Menu ID="Menu2" runat="server" Orientation="Horizontal">
         <Items>
         <asp:MenuItem NavigateUrl="~/Default.aspx" Text="HOME" Value="HOME"></asp:MenuItem>
             <asp:MenuItem NavigateUrl="~/About.aspx" Text="About" Value="About">
             </asp:MenuItem>
 
 <asp:MenuItem NavigateUrl="~/Contact.aspx" Text="CONTACT" Value="CONTACT"></asp:MenuItem>
 <asp:MenuItem NavigateUrl="~/Change.aspx" Text="CHANGE" Value="CHANGE"></asp:MenuItem>          </Items>
     </asp:Menu>
 
 </asp:ContentPlaceHolder>
    </form>
  Permalink  
v2
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

try site map for thispurpose.
 
Regard
sham
  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 6,676
1 OriginalGriff 6,056
2 CPallini 2,473
3 Richard MacCutchan 1,697
4 Abhinav S 1,560


Advertise | Privacy | Mobile
Web03 | 2.8.140821.2 | Last Updated 5 Sep 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