Download uploaded file from this article. In JQuery folder you will get two JQuery files first is 'jquery-1.3.2.js' and another is 'jquery.MultiFile.js'.
Default.aspx:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
<script src="jquery-1.3.2.js" type="text/javascript"></script>
<script src="jquery.MultiFile.js" type="text/javascript"></script>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:FileUpload ID="FileUpload1" runat="server"/>
<br />
<asp:Button ID="btnUpload" runat="server" Text="Upload All"
onclick="btnUpload_Click" />
</div>
</form>
</body>
</html>
Default.aspx.cs:
protected void btnUpload_Click(object sender, EventArgs e)
{
HttpFileCollection hfc = Request.Files;
for (int i = 0; i < hfc.Count; i++)
{
HttpPostedFile hpf = hfc[i];
if (hpf.ContentLength > 0)
{
hpf.SaveAs(Server.MapPath("MyFiles") + "\\" + System.IO.Path.GetFileName(hpf.FileName));
Response.Write("<b>File: </b>" + hpf.FileName + " <b>Size:</b> " + hpf.ContentLength + " <b>Type:</b> " + hpf.ContentType + " Uploaded Successfully <br/>");
}
}
}
Output: Press f5 and Select various images which you want to upload and click on 'Upload All' button. If you want to delete any selected image you may click on delete image button.

Figure 1:
After click on 'Upload All' button all selected images will save in appropriate directory and display successful message like as follows:


Lucas LopesPosted May 24, 2020, 9:18 AM EDT
How can I select multiple files instead of one at a time?
kiranPosted Jan 18, 2020, 10:44 AM EST
Multiple upload file to not showing remove option only single file name showing
kiranPosted Jan 18, 2020, 10:42 AM EST
Multiple file upload but at time remove option not showing plz help
Rajasekhar KollapuPosted Mar 4, 2016, 12:10 AM EST
Thank You
satish kumarPosted Nov 14, 2014, 4:10 AM EST
thanks
Ravikumar DPosted Apr 24, 2014, 4:15 AM EDT
how can i limit this to 5 files only and same time it is not selecting multiple files . How can we do that ?
Ravikumar DPosted Apr 24, 2014, 4:13 AM EDT
very nice and thanks
Subhankar BiswasPosted Mar 31, 2014, 2:02 AM EDT
add this Multiple="Multiple" class="multi" inside uploder control, after that you ca select multyple file.
kusuma AlekhyaPosted Mar 24, 2014, 5:01 AM EDT
ThanQ for the Post.
AmitPosted Dec 3, 2012, 9:27 PM EST
Hi, thanks for the post. Can we limit the no. of file selection?
keyur soniPosted Sep 11, 2012, 10:25 PM EDT
It is very helpful.....
Balaji SelvarajanPosted Jul 27, 2012, 5:30 AM EDT
Thanks for your Post. I need Single file upload using jquery. And Support IE Browsers Thanks
nagasaibabu neelaPosted Apr 10, 2011, 10:51 PM EDT
sry I am not able to select multiselection......
nagasaibabu neelaeditedPosted Apr 10, 2011, 10:49 PM EDTEdited Apr 10, 2011, 10:53 PM EDT
Hi, I am very thankful for ur work.But in this i am not able to select mutliple files at once.That means when i browse i have to select multiple files.can you please tell me regarding this.
annetPosted Feb 3, 2011, 11:40 PM EST
Hi, I have tried this code but it doesn't work for uploading more than one image. I need to upload one image at a time. Please help! Annet