Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_components thread: =?iso-8859-1?Q?Attn=3A_Torbj=F6rn=2E_and_Steve_=5Bcreate_and_S?=---=?iso-8859-1?Q?AVE_Excel_file_from_asp=5D?=


Message #1 by Hal Levy <hal.levy@s...> on Thu, 7 Jun 2001 10:04:33 -0400
Two people have commented about the same issue- Excel on the client.



Keep in mind that security comes into play here. The web browser, I 

believe,

will not have the rights to open Excel on the client through object

instantiation. 



In Steves case, you have created and Excel sheet, the user needs to 

save

this to their drive themselves. Even if you did have rights to create 

an

Excel object- you would create a new one. You would not have access to 

the

existing Excel application that is open.



in Torbj=F6rn's case- you need to do what Steve did. Send a header that 

says

"Open Excel for this" and then send the data from the web page. Excel

automatically converts HTML Tables into spreadsheets. Just make an HTML

table that looks like you want the spreadsheet to look like and send a

content type header before anything else gets sent.





Hal Levy

StarMedia Network, Inc.

Intranet Development Manager



-----Original Message-----

From: Steve Driscoll [mailto:SteveD@D...]

Sent: Thursday, June 07, 2001 8:50 AM

To: ASP components

Subject: [asp_components] Re: [create and SAVE Excel file from asp]





That would try to instantiate it on the server, not on the client.



-----Original Message-----

From: Yash from India [mailto:cool.yash@u...]

Sent: 07 June 2001 13:44

To: ASP components

Subject: [asp_components] Re: [create and SAVE Excel file from asp]







hi,



Why can't u try with server.createObject method to instantiate the 

Excel

dll.



<%

response.contenttype =3D "application/excel"

set objExcel=3D server.createObject("componet name")



%>



"bloch" <myriambloch@l...> wrote:

I Hello, I already created  my excel file from asp by using :

    Response.ContentType =3D "application/vnd.ms-excel"

but I need now to find the code to save this file right after its 

creation.



I also tried with :

Set xls =3D CreateObject("Excel.Application")

but it bugs  :

ActiveX component cannot create object: 'Excel.Application'



Thank.


  Return to Index