Solved

Using ActiveXObject to open excel within a Mac I/E session

Posted on 2004-04-30
5
841 Views
Last Modified: 2012-08-14
I am presently using ActiveXobject("excel.application") to download data into a excel worksheet from a html page in a Window environment.  I need to make the same thing work in a Mac environment.  

the code is actually:

<SCRIPT LANGUAGE="JavaScript">
<!--  Hide from non-JavaScript enabled browsers ');
'function AutomateExcel()
{
var oXL = new ActiveXObject("Excel.Application");
oXL.Visible = true;
var oWB = oXL.Workbooks.Add();
var oSheet = oWB.ActiveSheet;
var oSheet = oWB.ActiveSheet;
blah, blah....

thanks!
0
Comment
Question by:cmarshall
  • 4
5 Comments
 
LVL 63

Expert Comment

by:Zvonko
ID: 10963515
You need no ActiveX to load the worksheet.
Send the worksheet to browser and browser will display the worksheet in Excel.


0
 
LVL 63

Expert Comment

by:Zvonko
ID: 10963529
Or if you create the worksheet on the fly, then send it as html <table> and prepend the data with correct Excel MIME type.
0
 
LVL 63

Accepted Solution

by:
Zvonko earned 500 total points
ID: 10963537
Here an example from PAQ: http:Q_10226111.html

0
 

Author Comment

by:cmarshall
ID: 10980530
Can you describe the behavior of this on a Mac?  In my case, it will create a file, but not open the excel spreadsheet automatically.

TIA
0
 
LVL 63

Expert Comment

by:Zvonko
ID: 10981595
I do not have access to a Mac.

Also next time think about the advantage of giving grade A ;-)
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

This article discusses the difference between strict equality operator and equality operator in JavaScript. The Need: Because JavaScript performs an implicit type conversion when performing comparisons, we have to take this into account when wri…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

820 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