Sign In| Join
Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Nov 14, 2012 01:38 AM by Amy Peng - MSFT
Member
1 Points
15 Posts
Nov 09, 2012 09:24 AM|LINK
Hi, How to apply the CSS Class for Individual Dynamic menu item in ASP.net Menu control. below i am giving the control look like as:
<asp:Menu ID="cssTasksReports" runat="server" Orientation="Vertical" StaticDisplayLevels="1" > <StaticMenuItemStyle ItemSpacing="2" BackColor="#EAF4FF" ForeColor="#006699" Width="200" /> <StaticHoverStyle /> <StaticSelectedStyle /> <Items>
Here links will come from database </Items> </asp:Menu>
in the above code
<Items></Items> will come from the database here my doubt is how to apply css to these items these are webpages.
css will contain like: this is for menu items that are in <ul></ul> so instead of <ul> in need to create <asp:menu>
#panel {
width:200px;
list-style:none; padding-top:10px; display:inline-block; }
#panel li { border-radius:3px 3px 3px 3px; margin-top:5px; width:100px; background: #9999CC; background: background: -webkit-linear-gradient(top, #2F2727, #1a82f7); border-left:1px solid red; border-top:1px solid red; border-right:1px solid red; border-bottom:1px solid red; }
#panel li.animation { -webkit-transition: all 0.5s ease-in-out; -webkit-transform:translateX(0px); }
#panel li.animation:hover { -webkit-transform:translateX(25px); }
#panel li a { color:Green; display:block; padding:10px; }
#panel li a:hover { color:#00c6ff; }
</style>
Please let me know as soon as possible. Thanks in Advance. Regards, Raghu.
Star
10135 Points
960 Posts
Microsoft
Nov 14, 2012 01:38 AM|LINK
Hi,
Please try to refer to the following link, it can help you to solve the problem: http://www.dotnetcurry.com/ShowArticle.aspx?ID=811 .
Thanks, Amy Peng
raghavendra ...
Member
1 Points
15 Posts
how to apply style sheet to Dynamic item of asp.net menu control
Nov 09, 2012 09:24 AM|LINK
Hi,
How to apply the CSS Class for Individual Dynamic menu item in ASP.net Menu control. below i am giving the control look like as:
<asp:Menu ID="cssTasksReports" runat="server" Orientation="Vertical" StaticDisplayLevels="1" >
<StaticMenuItemStyle ItemSpacing="2" BackColor="#EAF4FF"
ForeColor="#006699" Width="200" />
<StaticHoverStyle />
<StaticSelectedStyle />
<Items>
Here links will come from database
</Items>
</asp:Menu>
in the above code
<Items></Items> will come from the database here my doubt is how to apply css to these items these are webpages.
css will contain like: this is for menu items that are in <ul></ul> so instead of <ul> in need to create <asp:menu>
#panel {
width:200px;
list-style:none;
padding-top:10px;
display:inline-block;
}
#panel li {
border-radius:3px 3px 3px 3px;
margin-top:5px;
width:100px;
background: #9999CC;
background: background: -webkit-linear-gradient(top, #2F2727, #1a82f7);
border-left:1px solid red; border-top:1px solid red; border-right:1px solid red; border-bottom:1px solid red;
}
#panel li.animation {
-webkit-transition: all 0.5s ease-in-out;
-webkit-transform:translateX(0px);
}
#panel li.animation:hover {
-webkit-transform:translateX(25px);
}
#panel li a {
color:Green;
display:block;
padding:10px;
}
#panel li a:hover {
color:#00c6ff;
}
</style>
Please let me know as soon as possible.
Thanks in Advance.
Regards,
Raghu.
Amy Peng - M...
Star
10135 Points
960 Posts
Microsoft
Re: how to apply style sheet to Dynamic item of asp.net menu control
Nov 14, 2012 01:38 AM|LINK
Hi,
Please try to refer to the following link, it can help you to solve the problem: http://www.dotnetcurry.com/ShowArticle.aspx?ID=811 .
Thanks,
Amy Peng
Feedback to us
Develop and promote your apps in Windows Store