apache-flexactionscriptflex3externalinterface

Using Activex Dll in Flex Web application


Correct me If I am doing wrong:

We have an existing web-application in Flex-BlazeDS-Spring running on JBoss. We need to read a Dll from client machine so we have used ExternalInterface.call like below:

ExternalInterface.call("eval", 
                         "try { "Test" + 
                         " = new ActiveXObject('DllName.FunctioninDll'); }" +
                          "catch(e) { document.getElementById('" + dis+ 
                          "').SetLastError(e.message); } ");

With the above code I receive "Automation Server can't create Object" error with Mozilla "ActiveXObject is not defined".

Kindly suggest If there is any work around

Thanks


Solution

  • ActiveX is only available in Internet Explorer. You could try using the HTML object tag, but I'm not sure if it will work.