Home > DeveloperSection > Forums > Styles.Render()
Ankita Pandey
Ankita Pandey

Total Post:183

Points:1285
Posted on    December-29-2012 3:19 AM

 ASP.NET MVC ASP.NET MVC 
Ratings:


 1 Reply(s)
 2286  View(s)
Rate this:
Hi every one

I'm new in MVC. can any one tell me how to use Styles using @Styles.Renderin our projects?

Thanks in advanced.


AVADHESH PATEL

Total Post:604

Points:4228
Posted on    December-29-2012 3:22 AM

Hi Ankita Pandey

It's calling the files included in that particular bundle wich is declared inside the BundleConfig class in the App_Start folder.

In that particular case The call to @Styles.Render("~/Content/css") is calling "~/Content/site.css".

bundles.Add(new StyleBundle("~/Content/css").Include("~/Content/site.css"));

you take references form given link

http://www.mindstick.com/Articles/2d3da74a-94da-45fe-b361-97263cd725f2/?Bundling%20and%20Minification%20in%20ASP.NET%20MVC%204

I hope it resolve your problem.

Don't want to miss updates? Please click the below button!

Follow MindStick