<contenttemplate>
<asp:Button ID="btnUpload" runat="server"
Text="Upload File"/>
<asp:ModalPopupExtender runat="server"
ID="modelPopupExtender1"
TargetControlID="btnUpload"
PopupControlID="popUpPanel"
OkControlID="btOK"
BackgroundCssClass="modalBackground">
<asp:Panel ID="popUpPanel" runat="server" CssClass="pnl">
<asp:AjaxFileUpload ID="AjaxFileUpload1"
runat="server"
OnClientUploadError="uploadError"
ThrobberID="myThrobber"
MaximumNumberOfFiles="1"
AllowedFileTypes=""
Width="200px" onuploadcomplete="AjaxFileUpload1_UploadComplete" />
<asp:Label runat="server" ID="myThrobber" Style="display: none;"><img align="absmiddle" alt="" src="uploaderImg/uploading.gif"/>
<asp:Label ID="lblMessage" runat="server"/>
<asp:Button ID="btOK" runat="server" Text="OK" />
<asp:LinkButton ID="LinkButton1" runat="server" CssClass="close"
OnClientClick="$find('modelPopupExtender1').hide(); return false;"/>
my .cs code is-------Ajax control is stopped at 98% to its progress bar and file is not upload.using ajax control in asp.net....plzzz help me...
protected void AjaxFileUpload1_UploadComplete(object sender, AjaxControlToolkit.AjaxFileUploadEventArgs e)
{
try
{
string path = Server.MapPath("~/worker/DiffImage") + e.FileName;
AjaxFileUpload1.SaveAs(path);
}
catch (Exception)
{ }
}