最近遇到在网页里调用activex的方法和属性,发现和网上说的不同:
<input id="Button1" type="button" value="button" onclick="return Button1_onclick()" />
<object id="tvs" width="600" height="400" type="application/x-oleobject" classid="clsid:859BB293-F63D-4452-B5D6-861770071536">
</object>
<script language="javascript" type="text/javascript">
// <!CDATA[
function Button1_onclick() {
document.all.tvs.SetUserName("hello");
}
// ]]>
</script>