Link to home
Start Free TrialLog in
Avatar of kayhustle
kayhustle

asked on

How to send csv file to client through FireFox

I want to send a csv file to a client from my asp .net application.  When I do the following
 Response.AddHeader("Content-Disposition", "mycsvfile.csv");      
Response.Write("[csv file elements]);                              
Response.End();
I get a csv file for IE, however in Firefox it gives me a mycsvfile.csv.txt file.  How do I make it so that it does not interpret the file as a txt file for Firefox?
ASKER CERTIFIED SOLUTION
Avatar of NBSO_ISS
NBSO_ISS

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of NBSO_ISS
NBSO_ISS

It also wouldn't hurt to do a

Response.Flush

Before

Response.End

In order to flush the memory.