URL routing broken in 5.1 upgrade
Been using Bootstrapper_Initialized in our global.asax to use some of our own custom routes to go along side sitefinity's.
been working great for the past year or so, but its broken today after 5.1 upgrade.
We're doing whats almost identical on this thread:
http://www.telerik.com/community/forums/aspnet-ajax/general-discussions/custom-routing.aspx
error we are receiving after 5.1 upgrade is:
this line:
var routes = (System.Web.Routing.RouteCollection)args.Data;Unable to cast object of type 'System.Linq.EnumerableQuery`1[System.Web.Routing.RouteBase]' to type 'System.Web.Routing.RouteCollection'.
bumping
Use something like the following in your Bootstrapper_Initialized method--it worked for me:
var routes = ((EnumerableQuery<
System.Web.Routing.RouteBase
>)args.Data).ToList<
System.Web.Routing.RouteBase
>();
System.Web.Routing.Route newRoute = new System.Web.Routing.Route("Your Route Here", new YourCustomRouteHandler());
routes.Add(newRoute);