468,140 Members | 1,456 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,140 developers. It's quick & easy.

Export Excel Report from ASP Output (Dynamic Stage)

Hai Evrybody,

I have one problem, that is i design a ASP report getting data from MS
SQL Server 2000 and displays it as a desinged format and also "one
option to export this same format to MS EXCEL". Before i seen it, but i
dont know its code. pls anybody tell or sent the its codings pls
my Mail Id :

sk****@jeevaninfotech.com
sh*************@yahoo.com

pls pls pls pls pls pls
pls pls pls
pls pls pls

Jun 19 '06 #1
1 1970
shankumar wrote:
Hai Evrybody,

I have one problem, that is i design a ASP report getting data from MS
SQL Server 2000 and displays it as a desinged format and also "one
option to export this same format to MS EXCEL". Before i seen it, but i
dont know its code. pls anybody tell or sent the its codings pls
my Mail Id :

sk****@jeevaninfotech.com
sh*************@yahoo.com

pls pls pls pls pls pls
pls pls pls
pls pls pls

<%
Response.AddHeader("Content-type","application/x-msdownload;application/excel")
Response.AddHeader("Content-Disposition","attachment;filename=filename.xls")
%>

use above lines for outputing data in excel format..
the above two line makes the browser to open a window to ask for save
or open an excel file..
then u concatenate ur table values to the structure what i gave below.
<%

strData="<table><tr><td>v1</td><td>v2</td><td>v3</td><td>v4</td><td>v5</td></table>"

response.write strData

%>
here v1 , v2 are values of a field of table

hope this will help u..

visu

Jun 19 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

16 posts views Thread by David Lauberts | last post: by
2 posts views Thread by PerryC | last post: by
2 posts views Thread by Arvind R | last post: by
1 post views Thread by suresh76 | last post: by
27 posts views Thread by didacticone | last post: by
1 post views Thread by gcdp | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.