Click here to Skip to main content
15,891,136 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I am using single image upload and save in data base.

My code-:
protected void btnUploadImage_Click(object sender, EventArgs e)
        {
            string filepath = null;
            if (fileUploadImage.HasFile)
            {
               filepath = Path.GetFileName(fileUploadImage.PostedFile.FileName);
               string fileFullpath = Server.MapPath("../../Content/ProductImage/") + filepath;
               fileUploadImage.SaveAs(fileFullpath);
            }      
        }
Posted
Updated 28-Jan-14 22:22pm
v2

1 solution

Try this link for multiple upload:

Implementing multiple file upload with progress bars within ASP.NET[^]

Multiple File Upload With Progress Bar Using Flash and ASP.NET[^]


[^]

To save in the database you have to convert the image to byte code and datatype should be blob.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900