NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Passing .NET object reference from TestStand Sequence to a LabView VI, called in the same sequence

Solved!
Go to solution

I think you either need to put it in the same directory as the LabVIEW.exe or you need to use a labview project and put it in the same directory as the project or something like that, I'm not that familiar with labview so you might want to post on the LabVIEW forum for more details about how labview finds assemblies. I'm pretty sure it doesn't just find them in labview search directories.

 

Hope this helps,

-Doug

0 Kudos
Message 21 of 29
(1,671 Views)

HI,

thank you for the answer. If it is the only solution to put the assembly into the LabView.exe directry 'll ask the system administrator to do it. What I can do myself is a LabView project, I'll try it and come back with a reasult.

Best regards

0 Kudos
Message 22 of 29
(1,667 Views)

Hi,

I made LabView project and put NET assembly in the same directory. For the usage in the LabView it is OK - it can find the assembly. But it doesn't work when I call this VI in a step of a Test Stand sequence. Obviously the only way is to put he assembly into LabView.exe directory.

Best regards

0 Kudos
Message 23 of 29
(1,665 Views)

Did you specify the labview project in your teststand step too?

 

-Doug

0 Kudos
Message 24 of 29
(1,659 Views)

Yes, I did.

0 Kudos
Message 25 of 29
(1,654 Views)

Maybe someone more familiar with labview than I am can help you. Perhaps someone on the LabVIEW forums will know.

 

-Doug

0 Kudos
Message 26 of 29
(1,651 Views)

Well, if I put NET assembly into LabView.exe directory it works. I believe it is some logic in this behaviour: Test Stand loads LabView and LabView gets the assembly. Maybe thesolution is to put the assambly in GAC. I maybe ask about it in LV-Forum, but the point is, that we need TestStand AND LabView together.

Thank you and best regards

0 Kudos
Message 27 of 29
(1,649 Views)

TestStand is just calling the VI using LabVIEW either via ActiveX if you are running in the development environment, or via the labview runtime engine if not. I do not know the details of how LabVIEW loads assemblies, however, someone on the LabVIEW forums might. I'm not sure why it would behave differently when run in LabVIEW vs. when run in TestStand.

 

-Doug

0 Kudos
Message 28 of 29
(1,639 Views)

Hi,

I went to LV forum with the question about the way of loading .NET assembly.

At the same time I tried another variant of working with the Teststand - using RunTime Engine (it is our baseline in any case). I made a VI, which uses .NET assembly, but the usage stays"inside" VI - there are no references which are to be passed to other VIs. The whole work with .NET assembly is done within VI. I set "Runtime Engine" in the Adapter Configuration and made several sequence steps using this VI.

 

Result: 1) the sequence runs OK, the result of every sequence step is correct

           2) when I close TestStand I get an error "Teststand can't run any more and has to be closed, you may search for solution, close or debug the program". Similar to the error I got working under Development Environment, but the error referred at first to Labview.

           3) Test Stand crashes already if I set a step option "show front panel". It is not necessary in any case, were useful only for control.

Does it mean that something (what?) is still false even in this configuration - RunTime Engine, nothing is passed between VIs?

Or can I ignore this fact (the sequence seems to work properly)?

best regards

 

0 Kudos
Message 29 of 29
(1,617 Views)