Object always retur 'undefined'

555 views
Skip to first unread message

D.Hadi

unread,
Aug 17, 2009, 5:51:09 AM8/17/09
to ff-activex-host

the following script work fine in IE but in ff & chrome
objNBioBSP.Device & objNBioBSP.Extraction is always 'undefined'

var objNBioBSP = document.getElementById("nbiobsp");
var objDevice = objNBioBSP.Device;
var objExtraction = objNBioBSP.Extraction;

i've tried using objNBioBSP.Device() but got error "objNBioBSP.Device
() is not a function"

below is the type definition from oleview

[
uuid(F66B9251-67CA-4D78-90A3-28C2BFAE89BF),
helpstring("NBioBSP Class")
]
coclass NBioBSP {
[default] interface INBioBSP;
[default, source] dispinterface _INBioBSPEvents;
};

[
odl,
uuid(4511B19F-37BC-437B-B18E-2106A9AF7083),
helpstring("INBioBSP Interface"),
dual,
oleautomation
]
interface INBioBSP : IDispatch {
[id(0x00000001), propget, helpstring("property ErrorCode")]
HRESULT ErrorCode([out, retval] long* pVal);
[id(0x00000002), propget, helpstring("property
ErrorDescription")]
HRESULT ErrorDescription([out, retval] BSTR* pVal);
[id(0x00000003), propget, helpstring("property Device")]
HRESULT Device([out, retval] VARIANT* pVal);
[id(0x00000004), propget, helpstring("property Extraction")]
HRESULT Extraction([out, retval] VARIANT* pVal);
[id(0x00000005), propget, helpstring("property Matching")]
HRESULT Matching([out, retval] VARIANT* pVal);
[id(0x00000006), propget, helpstring("property FPData")]
HRESULT FPData([out, retval] VARIANT* pVal);
[id(0x00000007), propget, helpstring("property FPImage")]
HRESULT FPImage([out, retval] VARIANT* pVal);
[id(0x00000008), propget, helpstring("property NSearch")]
HRESULT NSearch([out, retval] VARIANT* pVal);
[id(0x00000009), propget, helpstring("property
CheckValidityModule")]
HRESULT CheckValidityModule([out, retval] long* pVal);
[id(0x0000000a), propget, helpstring("property MajorVersion")]
HRESULT MajorVersion([out, retval] BSTR* pVal);
[id(0x0000000b), propget, helpstring("property MinorVersion")]
HRESULT MinorVersion([out, retval] BSTR* pVal);
[id(0x0000000c), propget, helpstring("property BuildNumber")]
HRESULT BuildNumber([out, retval] BSTR* pVal);
[id(0x0000000d), helpstring("method SetSkinResource")]
HRESULT SetSkinResource(BSTR bszSkinPath);
[id(0x0000000e), propget, helpstring("property IndexSearch")]
HRESULT IndexSearch([out, retval] VARIANT* pVal);
};


any help is appreciated.

regards

dhadi

Leeor Aharon

unread,
Aug 17, 2009, 6:21:05 AM8/17/09
to ff-acti...@googlegroups.com
Hi,

First of all, did you use the exe installer or the XPI? In order for it work in Chrome, you need to use the exe installer and not the XPI.

Second, you did not include the HTML you use to create the ActiveX so I can't be sure, but my bet is that you did not create a proper object tag. This plugin does not work with standard IE-compatible object tags. You need to write it slightly differently for it to work. Please read the documentation and go through other threads in this group.

Regards,
Leeor.

D.Hadi

unread,
Aug 17, 2009, 8:22:11 AM8/17/09
to ff-activex-host
Hi, thanks for the quick reply. I used the exe, flash activex shown in
the documentation works and i've browsed through all the previous
threads but to no avail. Anyhow here the html object tag that i used

<OBJECT id="nbiobsp" type="application/x-itst-activex"
classid="CLSID:F66B9251-67CA-4d78-90A3-28C2BFAE89BF"
height=0 width=0 VIEWASTEXT>
</OBJECT>

regards,


dhadi.

D.Hadi

unread,
Aug 17, 2009, 8:23:40 AM8/17/09
to ff-activex-host
Hi, thanks for the quick reply. I used the exe, flash activex shown in
the documentation works and i've browsed through all the previous
threads but to no avail. Anyhow here the html object tag that i used

<OBJECT id="nbiobsp" type="application/x-itst-activex"
classid="CLSID:F66B9251-67CA-4d78-90A3-28C2BFAE89BF"
height=0 width=0 VIEWASTEXT>
</OBJECT>

regards,


dhadi.

On Aug 17, 5:21 pm, Leeor Aharon <leeor.aha...@gmail.com> wrote:

Leeor Aharon

unread,
Aug 17, 2009, 8:51:32 AM8/17/09
to ff-acti...@googlegroups.com
You did not write the CLSID properly. You should not put the 'CLSID:' text, and the UUID needs to be surrounded with {}.

Please read the docs, this is all written there.

Leeor.

D.Hadi

unread,
Aug 17, 2009, 9:12:59 AM8/17/09
to ff-activex-host
Yeah sorry about that thought that clsid and classid were the same
thing. My bad.

Whilst trying i found out that you cant mix clsid and classid
together, I was mixing them both hoping for crossbrowser
implementation. is this intentional?

this works:

<OBJECT id="nbiobsp" type="application/x-itst-activex"
clsid="{F66B9251-67CA-4d78-90A3-28C2BFAE89BF}"
height=0 width=0>

this doesnt:
<OBJECT id="nbiobsp" type="application/x-itst-activex"
clsid="{F66B9251-67CA-4d78-90A3-28C2BFAE89BF}"
classid="CLSID:F66B9251-67CA-4d78-90A3-28C2BFAE89BF"
height=0 width=0>

Thanks


dhadi

D.Hadi

unread,
Aug 17, 2009, 9:15:45 AM8/17/09
to ff-activex-host
just ignore my last post i've just found out whats wrong

thanks

Leeor Aharon

unread,
Aug 17, 2009, 9:22:12 AM8/17/09
to ff-acti...@googlegroups.com
Again, PLEASE read the docs.

This is all explained in there, together with the reason for not implementing a cross browser solution.

Leeor.

mur...@theoremtechnology.net

unread,
May 19, 2018, 6:58:46 AM5/19/18
to ff-activex-host
Hi Hadi,

Me to facing the same issue. How did you resolve the same.
Reply all
Reply to author
Forward
0 new messages