Solved

Exporting to an Excel Database

Posted on 2003-11-19
9
412 Views
Last Modified: 2010-04-01
Hey,

I retrieve data from a database, put the information in a table(html) and allow the user of the application to view it in excel if he/she so chooses. I would like to put different tables into different workbooks inside excel.

Anyone have a suggestion?

Thanks,

Weber
0
Comment
Question by:webhsu
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
  • 2
9 Comments
 
LVL 3

Expert Comment

by:applekanna
ID: 9781901
set the contect type as "text/vnd.msexcel"
0
 
LVL 3

Expert Comment

by:applekanna
ID: 9781941
typo there

response.setContentType("application/vnd.ms-excel")
0
 
LVL 3

Expert Comment

by:applekanna
ID: 9781974
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:webhsu
ID: 9782210
I actually have exported data to excel already. just need to split it into different workbooks within the same excel session.
0
 
LVL 15

Accepted Solution

by:
jimmack earned 250 total points
ID: 9783616
Try this one:

http://www.tek-tips.com/gviewthread.cfm/pid/426/qid/536425

Scroll down to May 15 2003.  Tarwn explains how to do this using ASP, but apart from changing:

<%
Response.ContentType = "application/vnd.ms-excel"
%>

to

<%
response.setContentType("application/vnd.ms-excel");
%>

I think that should just about do it ;-)
0
 
LVL 15

Expert Comment

by:jimmack
ID: 9788548
Thanx.

I'm glad it's worked.  Could you confirm which versions of Excel this works with please?  (I'm a Linux user so it's a bit difficult to check ;-))
0
 

Author Comment

by:webhsu
ID: 9796675
office 2k.
0
 
LVL 15

Expert Comment

by:jimmack
ID: 9796826
Thank you ;-)
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The conference as a whole was very interesting, although if one has to make a choice between this one and some others, you may want to check out the others.  This conference is aimed mainly at government agencies.  So it addresses the various compli…
There are times when we need to generate a report on the inbox rules, where users have set up forwarding externally in their mailbox. In this article, I will be sharing a script I wrote to generate the report in CSV format.
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…
There are cases when e.g. an IT administrator wants to have full access and view into selected mailboxes on Exchange server, directly from his own email account in Outlook or Outlook Web Access. This proves useful when for example administrator want…

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question