LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Loadlibrary failed, with the FunctionName having UserDefined DataStructures

Hello , i have a COM Dll Which is having different functions. When I loaded the dll using Call Library function node, it is successful. But while selecting my Exposed function which is having UserDefined DataStructures it is giving Labview Run time error. But it is allowing other functions that do have the primitive data types. Can you please tell me how to overcome my problem? Here I am attaching my Com Dll please check it. There are 3 functions which use UDT's ie. IIinitializeCanCardDriver, ICAN_Write and ICAN_Read functions. Please let me correct if I am wrong path.
0 Kudos
Message 1 of 4
(2,889 Views)

I am able to access my Com Dll Exposed functions which is passing structures as parameters in the later versions of labview.

 

I have one more question , Can I capture the PostMessage functions sent by COM Dll in the Labview application and how?

 

Thanks in Advance

0 Kudos
Message 2 of 4
(2,840 Views)

rajeswari wrote:

I am able to access my Com Dll Exposed functions which is passing structures as parameters in the later versions of labview.


 

Could you please tell me how you made the structure so that everybody viewing this thread will get lot more information.

 

 


I have one more question , Can I capture the PostMessage functions sent by COM Dll in the Labview application and how?


You mean you want to get the return value of the function. You can just create an indicator to see its output. Correct me if i am wrong.

0 Kudos
Message 3 of 4
(2,838 Views)

Actually My COM Dll will have an exposed method which is passing a structure pointer as shown below

 

[id(1), helpstring("method InitializeCanCardDriver")] HRESULT IInitializeCanCardDriver([in]SInitCanCard *pInit,[out,retval] long *RetStat);

 

SInitCanCard is a structure pointer, which has the structure members of two long and one int type. But in this case, by using 7.1 version of labview when I am trying to select this function, I am getting run time error. But I tried it in 8.6 version, i am able to select this function.

 

My Question is, I will Post a Windows Message using PostMessage API call from my COM Dll. So that my client (VC / VB/ Labview client)should have a mechanism to hold this Message and get the value to be read from this. VC Client can access this value.But I don't have any idea how it is handled in Labview.Any suggestions?

 

Thanks in Advance.

Message 4 of 4
(2,836 Views)