What's the simplest way to let the user download a file in ASP.NET MVC ?

Posted by drasto on Stack Overflow See other posts from Stack Overflow or by drasto
Published on 2010-05-25T14:10:39Z Indexed on 2010/05/25 14:11 UTC
Read the original article Hit count: 198

Filed under:
|
|
|

In an ASP.NET MVC I have a database table. I want to have a button on some view page, if some user clicks that button I my application will generate XML file containing all rows in the database. Then the file containing XML should be sent to the client so that the user will see a download pop-up window.

Similarly I want to allow user to upload an XML file whose content will be added to the database.

What's the simplest way to let the user upload and download file ?

Thanks for all the answers

© Stack Overflow or respective owner

Related posts about c#

Related posts about asp.net-mvc