i selected image using file upload control....but i'm getting stuck on how to show in image box...
my code is:
if (FileUpload1.HasFile)
{
string f2 = "df.jpg";
String fileName = FileUpload1.FileName;
savePath += fileName;
FileUpload1.SaveAs(savePath);
Label1.Text = "Your file was saved as " + fileName;
Image1.ImageUrl = filename;
Image1.Visible = true;
if (fileName == f2)
{
Response.Write("<script>alert('Authentication Success')</script>");
}
else
{
Response.Write("<script>alert('Authentication Failed')</script>");
}
}
else
{
Label1.Text = "You did not specify a file to upload.";
}