Hello everyone,
I have a problem about fileupload control. I have created a fileupload control dynamically on code behind. And also i have created some textboxes, checkboxes and one button. There is a click event on the button. When i click the button, i can get all datas hold dynamic control except fileupload.
How can i get the dynamic fileupload data when i press the submit button. I get all datas via FindControl with control's ids.
Please help me about this problem ...
Thank you ...
Get Uploaded File Name from Dynamic FileUpload Control
1 Answer
Know the answer? Post it. Somebody with the same question will find it here.

Honey22 reputationPosted Sep 26, 2008, 2:37 AM EDT
Hi Xenomur,
HttpFileCollection uploadedFiles = Request.Files;HttpPostedFile userPostedFile = uploadedFiles[0];
string uploadedfilename=userPostedFile.FileName.ToString();
If you want to Store the file data any where, then you can use…..
userPostedFile.SaveAs(filepath);
May be this code is helpful to you....