0
我需要這種重定向在我的應用程序的情況發生:的MapPageRoute有類似routeURL
/汽車 去顯示,全cars.aspx
/車/ 1234 去編輯車。 ASPX
這是在Global.asax中我當前的代碼:
routeCollection.MapPageRoute("car-edit",
"car/{id}",
"~/car-edit.aspx",
true,
new RouteValueDictionary { { "id" } });
routeCollection.MapPageRoute("car-all",
"car",
"~/show-all-cars.aspx",
true);
出於某種原因,要在重定向到/車結果車edit.aspx代替根據需要顯示所有cars.aspx。
任何想法?
Webforms C#.NET 4.0