Hi,
I have file upload control and upload button in my application
asp:FileUpload ID="FileUpload1" runat="server" Width="250px" />
asp:Button runat="server" ID="btn_upload" Text="Upload"
onclick="btn_upload_Click"
i have included it in .aspx file
when i browse any file using this control and click on upload button
i got the connection timeout error.
.this case is only with fileupload control,but if i dint browse any file and click on upload button then this error is not coming,
click event of upload button(btn_upload_Click) gets fired but with Fileupload control after browsing any file click event of upload button not firing.
.why this problem occurs..plz help
2 回答
请在web.config文件中包含此项后尝试
<system.web> <httpRuntime executionTimeout="999999" maxRequestLength="2097151" /> </system.web>
在aspx文件中:
代码背后:
您也可以参考以下链接:
http://asp.net-tutorials.com/controls/file-upload-control/