Returning Multiple Files from MVC Action

后端 未结 4 632
死守一世寂寞
死守一世寂寞 2020-12-05 11:02

So I\'ve got an MVC 3 application that has a couple places where a text file gets generated and returned in an action using:

return File(System.Text.Encoding         


        
4条回答
  •  甜味超标
    2020-12-05 11:19

    Look at this SO solution: MVC Streaming Zip File

    The advantage of this solution is that it streams the file to the client.

    I just implemented this solution a couple of days ago and it worked fantastic.

提交回复
热议问题