代码如下。是专用终端。所以没有考虑ActiveXObject的安全问题。js不知道如何获取frame里的excle。以便放到客户端本地路径。
<html>
<head>
<meta HTTP-EQUIV="content-type"
CONTENT="text/html; charset=SHIFT_JIS">
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<meta name=ProgId content=Excel.Sheet>
<meta name=Generator content="Microsoft Excel 9">
</head>
<body>
<script type="text/javascript">
<form name="form1">
<br />
<div class="c1">
<input type="submit" value="保 存" name="save" onclick="tt()"/>
<input type="submit" value="提 交" name="send" onclick="readExcel()"/>
</div>
<a href="report/mayGrain.xls" >dd</a>
<iframe style="width: 500; height: 500" name="frm" id="frm"
src="report/mayGrain.xls">
</iframe>
</form>
</body>
</html>
<html>
<head>
<meta HTTP-EQUIV="content-type"
CONTENT="text/html; charset=SHIFT_JIS">
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<meta name=ProgId content=Excel.Sheet>
<meta name=Generator content="Microsoft Excel 9">
</head>
<body>
<script type="text/javascript">
<form name="form1">
<br />
<div class="c1">
<input type="submit" value="保 存" name="save" onclick="tt()"/>
<input type="submit" value="提 交" name="send" onclick="readExcel()"/>
</div>
<a href="report/mayGrain.xls" >dd</a>
<iframe style="width: 500; height: 500" name="frm" id="frm"
src="report/mayGrain.xls">
</iframe>
</form>
</body>
</html>
建议楼主研究一下dsoFramer,或者spreadsheet
1楼的朋友,有没有dsoFramer或spreadsheet的jsp的demo。就看到.net的demo。dsoFramer的官方网都挂了。进不去。
或提供相关信息的链接。谢谢了。
dsoframer在xp下OK的。
虽然它非常不稳定。
不过此方案不通。
没有在wince下的ocx,
xp上用的放到wince。编译不过,有引用到第三方类库。无法打开类型库:TypeLib\MSADDNDR.DLL