在 Preview 5 中,以下是运行良好的操作链接:
listing is the controller and about is the action
2.
var values = new RouteValueDictionary();
text and actionname are both strings
Html.ActionLink(文本,动作名称,值);
我将如何转换这些以在 RC 版本中畅通无阻?
在 Preview 5 中,以下是运行良好的操作链接:
listing is the controller and about is the action
2.
var values = new RouteValueDictionary();
text and actionname are both strings
Html.ActionLink(文本,动作名称,值);
我将如何转换这些以在 RC 版本中畅通无阻?
也许我不明白你的问题,但你上面的例子应该适用于 ASP.NET MVC RC。
我有同样的问题。
我得到了最新的 MVC Futures,并且修复了它。
http://aspnet.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=24142
不,在 RC 中使用这个会产生这个错误;
找不到方法:'System.String System.Web.Mvc.Html.LinkExtensions.RouteLink(System.Web.Mvc.HtmlHelper,System.String,System.Web.Routing.RouteValueDictionary,System.Web.Routing.RouteValueDictionary)'。