【发布时间】:2013-02-22 23:58:26
【问题描述】:
1) 在使用该行编辑视图时:
@Html.TextArea(name: "Message", rows: 10, columns: 40)
我在编译时收到此错误:
ERR: "The best overload for 'TextArea' does not have a parameter of type 'rows'"
即使存在以行和列作为参数的签名。
2) 所以我尝试使用签名: @Html.TextArea(字符串名称,对象 htmlAttributes)
如下调用函数
@Html.TextArea(name: "Message", new { rows=10, columns=40 }
但我遇到了另一个错误:
ERR: "Named Argument Specifications must appear after all fixed arguments have been specified"
有人知道为什么以及如何解决吗?
提前谢谢你!
【问题讨论】:
标签: asp.net textarea html-helper