简体   繁体   中英

How to create an activexobject using ip address in javascript?

I was trying the below code and getting "Automation server can't create object" error.

function GetAppVersion(){

var XLApp = new ActiveXObject("Excel.Application", "ipaddress"); 
return(XLApp.Version);

}

but if I use new ActiveXObject("Excel.Application") then I am not getting this error.

Please help me to avoid getting error on above code.

Assuming you are running this from a web page loaded in Internet Explorer, see the documentation :

Creating an object on a remote server can only be accomplished when Internet security is turned off.

Turn off Internet Security.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM