Hello All,
I am using FileUpload which is in cell of table. I am selecting file from local drive but when I click on Submit Button it shows no file. That is HasFile=false always.
I have one Update Panel in my page but FileUpload Control is out side of UpdatePanel.
I am also want that Multiple Files and attach it from another form. Like yahoo file attachment process.
How can I do that.
Please help me.
FileUpload Control of ASP.Net2 always shows HasFile=false. I dont know why?
Do you have permission to upload to your local directory? Can you post your code? Here's what I've used in the past:
protected void Button1_Click(object sender, EventArgs e)
{
if (FileUpload1.HasFile)
{
FileUpload1.SaveAs(@';C:\Inetpub\wwwroot\鈥?+ FileUpload1.FileName);
Label1.Text = ';File Uploaded: '; + FileUpload1.FileName;
}
else
{
Label1.Text = ';No File Uploaded.';;
}
}
UPDATE:
Have you tried debugging? Have you added the asp.net user to the folder (ComputerName/ASPNET)?
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment