Some code like this might do the trick for you, depending on the technique
you're using.
Response.AddHeader("Content-Disposition","attachment;filename=myfile.csv");
Here's a detailed tutorial on the subject of exporting to Excel from
ASP.NET:
http://www.aspnetpro.com/NewsletterA...200309so_l.asp
--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://Steve.Orr.net
"Neil" <an*******@discussions.microsoft.com> wrote in message
news:F6**********************************@microsof t.com...
Hi,
I'm currently exporting my datagrid to excel, taking advantage of the fact
that excel can render html, the problem is that when i click the button to
export it opens in browser, I want the button to launch Excel and leave the
browser as is.
Any help appreciated
p.s. I know that this can be achieved by changing the settings on the
client machine and de-selecting the 'browse in same window' for .xls
extensions but this is not acceptable for my clients.