I am trying to create packages of JS and CSS files. The folder structure is as follows:
I extracted some help from MVC Central and added this code to my project:
bundles.Add(new ScriptBundle("~/bundles/A/AAA").Include(
"~/Scripts/A/jquery-{version}.js");
bundles.Add(new ScriptBundle("~/bundles/B/BBB").Include(
"~/Scripts/A/jquery-{version}.js");
bundles.Add(new StyleBundle("~/Content/CSS/ACSS").Include("
~/Content/CSS/ACSS/MyCss-*"));
But it returns exception 404:
System.Web.HttpException (0x80004005): Controller for paths '/ bundles / A / AAA' not found or does not implement IController.
Edit: I registered my Bundles in a file Global.asax. so at least I'm not making a schoolboy mistake.
BundleConfig.RegisterBundles(BundleTable.Bundles);
What have I done wrong to cause this error?
source
share