context.Request.Form.Keys.count为零 [英] context.Request.Form.Keys.count is ZERO
本文介绍了context.Request.Form.Keys.count为零的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个简单的HTML页面,其中包含许多TextBoxes,CheckBoxes等.从那里提交一个通用处理程序称为(ASHX).
在处理程序中,当我尝试遍历请求表单的控件时,发现计数为零.
有什么会丢失的吗?
有任何想法吗?
I have one simple HTML page with number of TextBoxes, CheckBoxes etc. From there on Submit a Generic Handler is called (ASHX).
In handler, when I try to iterate through Request Form''s controls, I found the Count as ZERO.
Is there anything that would be missing ?
Any ideas ?
推荐答案
我解决了.
要在context.Request.Form.Keys中获取列表,应将"NAME"赋予HTML页面中的控件,这在我的页面中是缺失的.我只是指定了"ID"而不是"NAME"属性.
指定"NAME"之后....问题已解决!!!
I got it solved.
To get the list in context.Request.Form.Keys, "NAME" should be given to the controls in HTML page, that was missing in my page. I just specified "ID" and not "NAME" property.
After specifying "NAME".... issue was resolved !!
这篇关于context.Request.Form.Keys.count为零的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文