Click here to Skip to main content
15,032,755 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i m working with controlls.
its bound with database (sqlserver)

I have to use css to apply on it how should i do that ??
I dont have any css and not good at creating !!
Is there any css code to apply on dynamic menus???

My question is Need Css and How to apply on Dynamic Asp.menus???

You need a good book to read first before development!

Every ASP.NET server control has a property 'CssClass'
At runtime, when you generate menu items dynamically, just add the css class to the menu or more specific css to menu items.

Now you add a CSS stylesheet in your project from before having those css classes. You can add a reference to this CSS Stylesheet either from before or at runtime!

Read about CSS here:[^][^][^]
Whatever answer has suggested by Sandeep is correct. I just wanted to add few point overhere.

You can have a look into CSS Friendly Menu Adpater, which is much more handy for CSS implementation. As ASP.NET Menu is rendered into
. Which some times creates issue with CSS.

So, have a look into CSS Friendly Menu Adapter.[^]

You will find many more sample in net.

Hope this will help you

Thanks !

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

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900