szhswl
宋针还的个人空间

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<HEAD>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<TITLE></TITLE>

</HEAD>
<BODY>

<input name="shanghai" type="button" class="but" id="shanghai" onClick="StartExcel('上海')" value="上海店">

<SCRIPT LANGUAGE="Javascript">
var idTmr = "";

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

}

function Cleanup() {
window.clearInterval(idTmr);
CollectGarbage();
}

</SCRIPT>

</BODY>
</HTML>



---------------------------------------------------------------------------------------------------------------------------------
说人之短,乃护己之短。夸己之长,乃忌人之长。皆由存心不厚,识量太狭耳。能去此弊,可以进德,可以远怨。
http://www.blogjava.net/szhswl
------------------------------------------------------------------------------------------------------ ----------------- ---------
posted on 2007-12-04 15:15 宋针还 阅读(658) 评论(0)  编辑  收藏 所属分类: JAVASCRIPT

只有注册用户登录后才能发表评论。


网站导航: