嗨,我是asp.net的初学者,我正在尝试使用ajax updatepanel,updateprogress,这对我不起作用 [英] hi im a beginner in asp.net i'm trying to use ajax updatepanel, updateprogress which is not working form me
本文介绍了嗨,我是asp.net的初学者,我正在尝试使用ajax updatepanel,updateprogress,这对我不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<triggers>
<asp:PostBackTrigger ControlID="cmdAdd" />
</triggers>
<contenttemplate>
<table>
<td class="style26"><asp:Label ID="Label50" runat="server" Text="Upload">
</td>
<td class="style24">
<asp:FileUpload ID="FileUpload1" runat="server" Width="200px" Font-Names="Tahoma"
CausesValidation="True" ForeColor="#003399" Height="24px" MaxLength="500" FolderProcessingMode="Upload"
OnFileUploaded="FileUploaded" />
<a href="#" önclick="add()">Add<a href="#" önclick="Remove()">Remove</a>
</a></td>
</table>
<table>
<tr id="2" style="display: none">
<td class="style26">
<asp:Label ID="Label7" runat="server" Text="Upload">
</td>
<td align="left">
<asp:FileUpload ID="FileUpload2" runat="server" Width="253px" Font-Names="Tahoma"
CausesValidation="True" ForeColor="#003399" Height="24px" MaxLength="50" />
</td>
</tr>
</table>
<table>
<tr id="3" style="display: none">
<td class="style15">
<asp:Label ID="Label4" runat="server" Text="Upload">
</td>
<td align="left" class="style27">
<asp:FileUpload ID="FileUpload3" runat="server" Width="253px" Font-Names="Tahoma"
CausesValidation="True" ForeColor="#003399" Height="24px" MaxLength="50" />
</td>
</tr>
</table>
<table>
<tr id="4" style="display: none">
<td class="style15">
<asp:Label ID="Label9" runat="server" Text="Upload">
</td>
<td align="left" class="style27">
<asp:FileUpload ID="FileUpload4" runat="server" Width="253px" Font-Names="Tahoma"
CausesValidation="True" ForeColor="#003399" Height="24px" MaxLength="50" />
</td>
</tr>
</table>
<table>
<tr id="5" style="display: none">
<td class="style15">
<asp:Label ID="Label10" runat="server" Text="Upload">
</td>
<td align="left" class="style27">
<asp:FileUpload ID="FileUpload5" runat="server" Width="253px" Font-Names="Tahoma"
CausesValidation="True" ForeColor="#003399" Height="24px" MaxLength="50" />
</td>
</tr>
</table>
<table>
<tr>
<td class="style28">
<asp:Label ID="Label3" runat="server" Text="Keywords">
</td>
<td align="left" class="style29">
<asp:TextBox ID="keyword1" runat="server" TextMode="MultiLine" Width="327px" Font-Names="Tahoma"
CausesValidation="True" ForeColor="#003399" Height="50px" MaxLength="150">
</td>
</tr>
</table>
<div id="tablewrapper">
<div id="tableheader">
<span class="details">
<table class="style1">
<tr>
<td class="Name" align="center">
<asp:Button ID="cmdAdd" runat="server" Text="SAVE" Width="84px" Font-Bold="True"
Font-Names="Tahoma" Font-Size="X-Small" OnClick="cmdAdd_Click" OnClientClick="showWait" />
<asp:Button ID="cmdupdate" runat="server" Text="MODIFY" Width="84px" Font-Bold="True"
Font-Names="Tahoma" Font-Size="X-Small" OnClick="cmdupdate_Click" />
<asp:Button ID="cmdDelete" runat="server" Text="DELETE" Width="84px" Font-Bold="True"
Font-Names="Tahoma" Font-Size="X-Small" OnClick="cmdDelete_Click" />
<asp:Button ID="cmdCancel" runat="server" Text="RESET" Width="84px" Font-Bold="True"
Font-Names="Tahoma" Font-Size="X-Small" OnClick="cmdCancel_Click" />
</td>
</tr>
<asp:UpdateProgress ID="UpdateProgress1" runat="server"
AssociatedUpdatePanelID="UpdatePanel1">
<progresstemplate>
<asp:Label ID="lblWait" runat="server" BackColor="#507CD1"
Font-Bold="True" ForeColor="White"
Text="Please wait ... Uploading file">
</progresstemplate>
</table></span></div></div></contenttemplate>
This is my html code is there any mistake or will i have to do anything on serverside(C#)
This is my html code is there any mistake or will i have to do anything on serverside(C#)
推荐答案
need to add <@register namespace=\"ajaxcontroltoolkit\" tagprefix=\"uc1\">
and
<asp:scriptmanager id=\"scripmanager1\" runat=\"server\">
need to add <@register namespace="ajaxcontroltoolkit" tagprefix="uc1">
and
<asp:scriptmanager id="scripmanager1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server" />
use this
use this
Try this solved example
Showing File Upload Progress to the user using UpdatePanel control in ASP.NET[^]
Thanks
Try this solved example
Showing File Upload Progress to the user using UpdatePanel control in ASP.NET[^]
Thanks
这篇关于嗨,我是asp.net的初学者,我正在尝试使用ajax updatepanel,updateprogress,这对我不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文