我使用updatepanel时无法读取Fileupload文件名 [英] Fileupload filename not reading when i use updatepanel

查看:50
本文介绍了我使用updatepanel时无法读取Fileupload文件名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用VS 2010.在我的页面中,我使用脚本管理器和更新面板.我在其中放置了Fileupload工具,但是当我在运行项目时未读取文件名时,如何使用更新面板读取Fileupload文件名.

I am using VS 2010.In my page i use script manager and update panel.I place Fileupload tool in that ,but when filename not read when i run the project.How can i read fileupload filename with using update panel.

推荐答案

有据可查的是FileUpload控件与UpdatePanel不兼容.
It is well documented that the FileUpload control is not compatible with UpdatePanel.


您可以创建文件上传的新表单. html中有input标签,用于浏览文件.您需要使用上载选项来执行一些代码.

You can create new form for file upload. input tag is there in html for browse the files. You need to do some code with the upload option.

<input id="FindFile" style="Z-INDEX: 101; left: 5%; width: 95%; top:10%; height: 22px" type="file" size="26" runat="server" name="FindFile" />




选中 [ google [
Hi,

Check this[^].
Also if you make a simple google[^] search you will find solution how to make it work inside update panel...
Solution is to add PostBackTrigger to your update panel...


这篇关于我使用updatepanel时无法读取Fileupload文件名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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