【发布时间】:2012-07-23 19:25:25
【问题描述】:
我需要将文件名变量分配给ashx页面中的隐藏字段值,如何为ashx页面中的隐藏字段分配值?
.ashx 页面
public void ProcessRequest(HttpContext context)
{
var file = context.Request.Files[0];
//here i need to pass this file name in hidden field value
}
这是存在隐藏文件的 aspx 页面
<asp:HiddenField ID="hdnFileName" runat="server"/>
【问题讨论】:
-
这没有任何意义;该页面在任何地方都不存在。
-
嗨,我想保存我在文件处理程序中得到的文件名,即 ashx 页面,我想在 webservcie 中使用它,那我该怎么做呢?
标签: c# filehandler