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

Popular posts from this blog

java - Oracle EBS .ClassNotFoundException: oracle.apps.fnd.formsClient.FormsLauncher.class ERROR -

c# - how to use buttonedit in devexpress gridcontrol -

nvd3.js - angularjs-nvd3-directives setting color in legend as well as in chart elements -