Home > Web Front-end > JS Tutorial > 在 IE 中调用 javascript 打开 Excel 表_javascript技巧

在 IE 中调用 javascript 打开 Excel 表_javascript技巧

WBOY
Release: 2016-05-16 19:23:00
Original
1064 people have browsed it

nbsp;HTML PUBLIC “-//W3C//DTD HTML 4.0 Transitional//EN“>



打开Excel表






<script> <BR>var idTmr = ““; <br><br>function StartExcel(strFileName) <BR>{ <BR>var oExcel; <BR>var oWorkbook; <BR>var strAllName; <BR>oExcel = new ActiveXObject(“Excel.Application“); <BR>//if(strFileName=null || strFileName=““) <BR>//{return; <BR>//} <BR>strAllName=“\\\ep-hgh\\Top30销控表\\TOP30招商续约销控表-“+strFileName+“.xls“; <BR>oExcel.Workbooks.Open(strAllName); <BR>//oExcel.Workbooks.Open(“file://ep-hgh/Top30销控表/TOP30招商续约销控表-上海.xls“); <BR>oExcel.DisplayAlerts = false; <BR>oExcel.Visible = true; <BR>//oExcel.Quit(); <BR>//oExcel = null; <BR>//防EExcel死进程的关键!!必须!!!downmoon严重声明 <BR>idTmr = window.setInterval(“Cleanup();“,1000); <BR>} <br><br>function Cleanup() { <BR>window.clearInterval(idTmr); <BR>CollectGarbage(); <BR>} <br><br></script>


Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template