Re: How to call DLL in Javascript

From: Date: Tue, 17 Nov 2009 13:24:45 +0000
Subject: Re: How to call DLL in Javascript
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-299890@lists.php.net to get a copy of this message
Peter wrote: > Hi All, > > I want to call dll in javascript > > I tried the following script, but i got the error message 'ActiveXObject > is undefined' > (Note : i have the feedback.dll in the same path only) > > > <HTML> > <HEAD> > <script type='text/javascript' language='javascript'> > function comEventOccured() > { > > try{ > var myobject; > myobject = new ActiveXObject("feedback.dll"); > }catch(e){ > alert(e.description); > return false; > } > > } > </script></head> > <body> > <input type=button value="Call the DLL" > onClick="comEventOccured()"> > </body> > </html> > > > > Regards > Peter. usually .dll should be running client side not server side jscript and javascript are two different beasts based on ecmascript; you'll be wanting to get some JScript (microsofts own version) help for this.. http://msdn.microsoft.com/en-us/library/7sw4ddf8%28VS.85%29.aspx but as somebody else mentioned, you won't get it working on all browsers AFAIK.. so running DLL on server side and calling wrapper functions via ajax is more appropriate. an asp.net forum or suchlike will probably yield a more useful response regards

« previous php.general (#299890) next »