c# - unable to download file from server in asp.net application -
i having exception when try download file server in asp.net application :
this code :
try { response.appendheader("content-disposition", "attachment; filename=" + "toto"); response.transmitfile(server.mappath("fda//toto.txt")); response.end(); } catch (exception ex) { var exception = ex; }
and exception when debug code , put breakpoint @ "catch exception":
ex = {unable evaluate expression because code optimized or native frame on top of call stack.}
when run code without debuging , no breakpoints, getting :
my code stop in "scriptresource.axd.....acab[dynamic] page @ line "throw error" following visual studio pop :
sys.webforms.pagerequestmanagerparsererrorexception:
and have 3 buttons on pop : break, continue, ignore.
Comments
Post a Comment