I want to load routes on every requests, i have tried to put it this code RegisterBundles(RouteTable.Bundles)
to the Application_Beginrequest
.
seems this method helped me but also now when i refresh the page i am getting an errors on browser.
How can i load routes dynamically from database without an error?
As i say i was thinking about the routing problem. Problem is when routing loads dynamically than it seems same route is loading again and it makes problem for scriptresources and bundling.
I put routes.Clear();
before load the routes and my problem is disappeared.
I hope this information will help you to understand your problem and you can solve this error just like that.
Cheers
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.