文件上载控件不更新面板内部组件 [英] File upload control not working inside update panel
本文介绍了文件上载控件不更新面板内部组件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我用下面的code上传文件
I am using the following code to upload the file
<asp:UpdatePanel ID="UpdatePanel18" runat="server">
<ContentTemplate>
<asp:FileUpload runat="server" ID="fuImage1" />
<asp:Button runat="server" ID="btnUpload1" Text="Upload"
onclick="btnUpload1_Click" />
<asp:ImageButton ID="btnGetImage1" ImageUrl="images/cam.png" Height="25px"
Width="25px" runat="server" onclick="btnGetImage1_Click" />
</ContentTemplate>
<Triggers>
<asp:PostBackTrigger ControlID="btnUpload1" />
</Triggers>
</asp:UpdatePanel>
当我选择要上传的文件,是没有得到显示在文件上传控制路径。需要帮助解决这个问题。
When i select a file to upload, path is not getting displayed on the file upload control. Need help to fix this problem
推荐答案
这是更新面板的一个令人沮丧的特点。给这篇文章读肚里在这个问题的原因以及分辨率:
This is a frustrating feature of the update panel. Give this post a read which goes over the cause of this issue as well as a resolution:
的http://geekswithblogs.net/mmintoff/archive/2009/04/01/fileupload-within-updatepanel.aspx
这篇关于文件上载控件不更新面板内部组件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文