Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel object -open within browser? 3

Status
Not open for further replies.

kruby

Programmer
Jun 26, 2001
22
CA
Hi,

I'm wondering if anyone can tell me how the following was done, as we would like to incorporate it in one of our web pages.

I went to a website today and the page showed data in rows and columns (formatted in tables). They had a link called "Excel" and if you clicked on the link, an Excel worksheet opened WITHIN the browser window. I tried checking the souce, but all I found was that they are using ASP.

We would like this functionality, too! I think it's great because the data is already formatted for Excel and you have the same functionality as an Excel worksheet. We were then able to copy the worksheet directly in the Excel application (from the browser).

Can anyone tell me how this was done, any websites that tell how this was done or any useful advice?

Thanks very mucy
 
Excel will just open itself in IE -- blends right in to the browser window -- no special widgets needed. Just put your .xls file on the server, and provide a link.

Here's a FAQ on not only how to open up the Excel sheet, but a javaScript function that you can attach to a button that will copy the contents of a table to your clipboard and open up an Excel sheet that your user will then only need to [CTRL]-V to paste in the contents --

faq216-738

I use it all the time for printable web reports...

:)
Paul Prewett
penny.gif
penny.gif
 
Change the ContentType to the appropriate MIME so the browser knows how to interpret what it's receiving, like so:

<%response.ContentType = &quot;application/vnd.ms-excel&quot; %>

<table><tr><td> <%=Now()%> </td></tr></table> Jon Hawkins
 
Thanks very much the links and the tips! I think's the functionality is really neat and so useful.

The same day that I saw this done with Excel, I went to another site and Word opened within the browser, too.

Just wondering if this was something new as I've never seen this done before?

Thanks!

 
Look into Office Web Components... I know that if you install them on your web server, you can get access to word, excel, etc.

I also know that when you export from Excel into a dynamic web page, the web server needs to have OWC installed. This is probably the functionality that you are talking about (excel, word - opening up in MSIE).

hth
leo leo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top