hi
i m create a website in asp.net 3.5 and upload on the webspaces.
but i m able to upload the file but i m not downlod the file
i try my many codes to download file from my website .
and get one error "This is not a irtule path "
i m use server.mathpath but this is return whole path which contains the hosting providing path with drive path . this is not use ful for me
please help me
please help me in code
How to download file From My website
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.


CrishRank #1,487 · 1.1K reputationPosted Jun 20, 2010, 9:37 PM EDT
thanks
Don't forget to Mark Do you like this Answer
that solved your problem!
ArshadRank #2,492 · 564 reputationPosted Jun 21, 2010, 8:23 PM EDT
Response.ContentType = "image/jpeg";
Response.AppendHeader("Content-Disposition","attachment; filename=arshad.jpg");
Response.TransmitFile( Server.MapPath("~/images/arshad.jpg") );
Response.End();
Regards,
Arshad