title: asp.net mvc create csv file in memory without creating a physical file and send email as attachment
body: <p>I'm working on asp.net mvc web application development, where I need to create a CSV file in-memory and send as attachment of email.</p>
  
  <p>I had a look at this stack overflow solution below:
  <a href="https://stackoverflow.com/questions/11983586/export-c-sharp-list-to-csv-file">Export C# List to Csv file</a></p>
  
  <p>Unfortunately, this solution returns File Result and doesn't fit with my requirement.</p>
  
  <p>Any help will be much appreciated.</p>