how to export query results into csv or text file
give me code
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Anubhav ChaudharyPosted Jan 17, 2015, 3:19 AM
Why are you posting your question on someone else question?? Make a new question and ask your problem over there.
rakesh mhatrePosted Jan 17, 2015, 3:04 AM
Thank u
Anubhav ChaudharyPosted Jan 17, 2015, 2:38 AM
You will get code from here:
http://www.c-sharpcorner.com/UploadFile/cd7c2e/export-sql-data-to-excel-using-Asp-Net/
You just need to make one change in the code, just replace
Response.ContentType = "application/excel";
with this
Response.ContentType = "application/vnd.text";