LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

ActiveX Library behaving differently in IDE and Runtime (Adressing a Horiba Spectrometer)

Hello,

I have a problem with an ActiveX-DLL. The DLL is used to talk to a Spectrometer. If I run the VI from the development environment everything works. If I build the exe and run it, the DLL throws an error ("SDK Hardware Key not found. Insert Key to continue").
There is already a thread for this library and problems with it (https://forums.ni.com/t5/SignalExpress/Error-quot-SDK-Hardware-Key-Not-Found-quot/td-p/786744/highli...). Someone even postet the problem with the runtime but got no answers.

I attached the code as a screenshot.
I'm using Labview 2014 32bit on Windows 7 64 bit.

Has anybody an idea what might be the problem?

Thank you very much for your help.

Kind Regards
Michael Roth

0 Kudos
Message 1 of 8
(2,702 Views)

There is another post referenced in the one you mentioned that talks about modifying registry settings.  Maybe something there will help you????

aputman
------------------
Heads up! NI has moved LabVIEW to a mandatory SaaS subscription policy, along with a big price increase. Make your voice heard.
0 Kudos
Message 3 of 8
(2,667 Views)

I haven't dug deep into the registry and the other hardware stuff, because in the VI works. It's just if I build the exe I get the error. So there has to be something different between the VI and the exe. I don't get it why it works in the VI and not in the exe. I can't debug anything (at least I don't know how) because the error is thrown in the ActiveX-Library. So I'm looking for things that are different between VI and exe and how that could affect the call of the library. But until know I don't have an idea.

0 Kudos
Message 4 of 8
(2,656 Views)

@Michael_Roth wrote:

I haven't dug deep into the registry and the other hardware stuff, because in the VI works. It's just if I build the exe I get the error. So there has to be something different between the VI and the exe.


Yes, the SDK component might actually check if it's being used in a development environment or executable environment. See this. So developers can develop an application and then have to pay\register to use it in an executable.

 

Just for fun, try to rename your exe to LabVIEW.exe. It might just work... Not that it solves the problem if it would, but at least you'll know the component does this check.

 

Has any of you (other threads OP's) ever contacted Horiba?

 

Have you tried to run the exe as administrator? LV has those rights, your exe doesn't.

Message 5 of 8
(2,650 Views)

Renaming the exe to LabVIEW.exe did the trick.

I haven't found a license agreement for the SDK, so I don't know if there is a restriction to use it for executables. Maybe it's not even intentional by Horiba. It could be that the SDK checks whether it is used by LabVIEW or an other language and then makes adjustments. Their VIs don't look very professional. So maybe they don't know that much about LabVIEW and it's just a bug. But that's just speculation from my part.

 

Thanks a lot for your help. I'll contact Horiba and ask what's their opinion on this.

0 Kudos
Message 6 of 8
(2,645 Views)

>Renaming the exe to LabVIEW.exe did the trick.

Didn't expect that...

 

>So maybe they don't know that much about LabVIEW and it's just a bug.

Sadly, usually an intern makes these interfaces when company sees growth potential. nothing wrong with interns, but they're simply not up for the job.

 

>I'll contact Horiba and ask what's their opinion on this.

Please post your findings.

0 Kudos
Message 7 of 8
(2,639 Views)

I haven't gotten an answer from Horiba yet ...

0 Kudos
Message 8 of 8
(2,628 Views)