Downloading multiple files

M

Maury

Hello,
I would like to download multiple files with one click
in a web form link, I know how to download a single
file, and I think that a solution is to zip
all the files in an archive, and then downloading it,
but I'm looking fo another solution, do you think
that is is possible another way?
Thanks!
..:M:.
 
B

Baski

Assume if you want 5 file upload , add 5 upload html control in to your page
or use for loop to add as many upload file control you want. On the submit
button event handler you can use the following code to parse thru all the
files

HttpFileCollection HttpFiles = Request.Files;
for (int i = 0; i < HttpFiles.Count; i ++)

{

HttpPostedFile _HttpPosted = HttpFiles;

//Here you can do what ever you want to do with this file ,

// save or open and process without saving the file using the stream.

}



Thanks

Baski
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,773
Messages
2,569,594
Members
45,124
Latest member
JuniorPell
Top