Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- httpFileCollection uploads=HttpContext.Current.Request.Files;
- //Store
- Session["UploadedFiles"] = uploads;
- //Retrieve
- if (Session["UploadedFiles"] != null)
- {
- //try-catch blocks omitted for brevity. Please implement yourself.
- HttpFileCollection myUploads = (HttpFileCollection)Session["UploadedFiles"];
- // Do something with the HttpFileCollection (such as Save).
- // Remove the object from Session after you have retrieved it.
- Session.Remove("UploadedFiles");
- }
Add Comment
Please, Sign In to add comment