Display image after upload without page refresh or PostBack in ASP.Net

Last Reply 12 days ago By pandeyism

Posted 12 days ago


i am using file upload control to upload file in directory

<asp:AjaxFileUpload ID="AjaxFileUpload11" runat="server" MaximumNumberOfFiles="5"
    Width="400px" OnUploadComplete="OnUploadComplete" />

  <asp:Image ID="Image1" runat="server" />


protected void OnUploadComplete(object sender, AjaxFileUploadEventArgs e)
    string fileName = Path.GetFileName(e.FileName);
    string filePath = "~/Uploads/" + fileName;
    AjaxFileUpload11.SaveAs(Server.MapPath("~/Uploads/" + fileName));

i want after image successfully uploaded it should bind with image control above without full postback please advice

You are viewing reply posted by: pandeyism 12 days ago.