加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

.net – 如何清除asyncfileupload的文本框值?

发布时间:2020-12-16 02:50:10 所属栏目:百科 来源:网络整理
导读:有一个按钮(MyButton). 单击此按钮会出现一个modalpopup(MyPopup),其中包含一个asyncfileupload ajax控件,“确定”按钮和“取消”按钮. asyncfileupload功能的浏览功能正常,没问题. 但是在回发之后,如果我再次单击MyButton,弹出窗口将出现在asyncfileupload
有一个按钮(MyButton).
单击此按钮会出现一个modalpopup(MyPopup),其中包含一个asyncfileupload ajax控件,“确定”按钮和“取消”按钮.

asyncfileupload功能的浏览功能正常,没问题.
但是在回发之后,如果我再次单击MyButton,弹出窗口将出现在asyncfileupload控件的文本框中的上一个路径中.

如何清除它……!

提前致谢.

解决方法

所提出的方法都不适合我.
问题不是特定于AsyncFileUpload,而是输入[type = file].

最后,我找到了一种适用于javascript的方式:

function uploadComplete(sender,args) {
    jQuery(sender.get_element()).find("input[type='file']")[0].form.reset();
}

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读