[Home]
[Edit this page]
[Recent Changes]
[Special Pages]
[Help]
ASPFAQ_Open_Excel_Application_Server_Side
We use the Server.CreateObject("Excel.Application") to create a new application object then we set its visibility property to true.
Workbooks.Open(myExcel.xls) displays the workbook of the Excel file name specified between the parentheses.
Related threads:
Back to ASP FAQ
[Edit this page] [Page history] [What links here] [Discuss this topic] [Printer Friendly]
ASPFAQ_Open_Excel_Application_Server_Side
How to open an MS Excel application on the server?
The example shows how to open an MS Office Excel application on the server. It can be useful when dealing with lots of documents in a proprietary format that the users want to view or edit but they may not have the specific application on their client machine.<% @Language=VBScript%>
<% Option Explicit %>
<html>
<head><title>Open Excel on Server</title>
</head>
<body>
<%
Dim appExcel
Set appExcel = Server.CreateObject("Excel.Application")
appExcel.Visible = True
appExcel.Workbooks.Open(myExcel.xls)
%>
</body>
</html>We use the Server.CreateObject("Excel.Application") to create a new application object then we set its visibility property to true.
Workbooks.Open(myExcel.xls) displays the workbook of the Excel file name specified between the parentheses.
Related threads:
Back to ASP FAQ
[Edit this page] [Page history] [What links here] [Discuss this topic] [Printer Friendly]
