【发布时间】:2017-04-16 04:38:56
【问题描述】:
Routeconfig 中有如下路由
routes.MapRoute(
name: "WithParams",
url: "{controller}/{action}/{langue}/{AffID} ",
defaults: new { controller = "Home", action = "Index", AffId = "", langue = "" }
);
我正在尝试从系统的某些部分调用此路由。
Response.RedirectToRoutePermanent("WithParams", new RouteValueDictionary { AffId :123,langue:"EN" });
出现语法错误,如何在上述重定向中传递查询字符串参数。
【问题讨论】:
标签: asp.net-mvc asp.net-mvc-4 c#-4.0 routes