views:

248

answers:

1

Hello, I have an ActiveX object which extends some functions. I have a web page that loads the ActiveX object and calls its methods in Javascript. The ActiveX object has two method; the problem is that Javascript can successfully call one of them but fails to call the other; citing Object doesn't support this property or method which is nonsense because I made a VB6.0 application that successfully calls this other method, so the two functions are indeed extended correctly and performing their job.

And yes, the Internet Explorer security zones are all set and everything, as I wrote above the javascript code can call one method but refuses to call the other.

Any idea why Javascript is being a headcase?

A: 

The answer was pretty simple. In the IDL file the function was declared as a property (propget) without taking any input arguments. In the Javascript code, I was calling actvx3obj.ATR(); when in fact I should have been calling actvx3obj.ATR; because it is a property get method that takes no argument.

I'm posting this in the hopes that someone with a similar problem may stumble upon the solution.

Voulnet