在FormCollection MVC3中获取HTML Table的行 [英] Take Html Table's rows in FormCollection MVC3

查看:96
本文介绍了在FormCollection MVC3中获取HTML Table的行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



现在,我真的对MVC3中的表单收集感到困惑.我在视图页面中添加了名为"idxtbl"的HTML表.然后我填充了5行.页面回发后如何获取所有行?

Hi,

Now i am really confused about formcollection in MVC3. I add HTML table ,named "idxtbl", in my view page. Then i populated with 5 rows. How should i get all the rows when page is post back ?

Private ActionResult GetRow(Formcollection frmcol){
          //How should i get all the rows in HTML table from GetRow View Page.
}


谢谢,
frog


Thanks,
frog

推荐答案

您可以尝试将集合绑定到表中的数据,但是我强烈怀疑您将遍历表单数据以查找和解析它自己.有一些用于MVC3和表的框架,也许它们会有所帮助(不,我没有使用过)
You might try binding a collection to the data in your table, but I suspect strongly that you''ll be iterating over the form data to find and parse it yourself. There are some frameworks for MVC3 and tables, perhaps they will help ( no, I''ve not used one )


这篇关于在FormCollection MVC3中获取HTML Table的行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆