Actor Framework Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

How do you build an executable with a Linked Network Actor?

Solved!
Go to solution

I apologize for what must be a very low level problem.  I'm new to using Labview Community and I'm not sure where I'm supposed to post anything yet.

I have started using the Linked Network Actor and to be honest I've been having a lot of fun.  However I have encountered a problem where I seem to be unable to launch a linked network actor after I have built my code into an executable. 

I've attached a test script that has a very simple labview project that launches a single Linked Network Actor (with its front panel visible). 

When running this in the development environment the program launches the Linked Network Actor front panel and when stopped closes without error.

When running this as an executable the program it does not launch the Linked Network Actor front panel and generates an error when stopped when it tries to send the actor a stop message.

How do you build an executable with a Linked Network Actor?

I imagine/hope this is something simple that I am not understanding.

Thanks again for your assistance.

Sincerely,

Sean

0 Kudos
Message 1 of 13
(7,389 Views)
Solution
Accepted by topic author cerebus

Is it an Error 1634?  The option on Launch Actor.vi to open Actor Core is not supported in executables; you will get Error 1634 if you try.

0 Kudos
Message 2 of 13
(4,488 Views)

I'm afraid not.  It's error 1556.  The same error as if you try to stop an actor that is no longer running.

0 Kudos
Message 3 of 13
(4,488 Views)

Although the error does go away when you don't enable the boolean on the launch actor.vi.

Thank you niACS, I think you may have solved my problem.

0 Kudos
Message 4 of 13
(4,488 Views)

Can you communicate at that point?  Also, are you trying to talk between application instances on the same machine?  I.e. are you running the executable and trying to talk to it with a test harness in the development environment running on the same computer?

0 Kudos
Message 5 of 13
(4,488 Views)

Try checking to make sure that your actor core for the linked network actor does not have its front panel removed in your build, under source file settings.  I can't seem to attach an image in this forum, otherwise I'd point it out.

Message 6 of 13
(4,488 Views)

I use the LNA to talk between 2 executables (one runs permanantly whenever the PC is on as a Windows service, the other is the user interface program).

What I found is that when they are in separate executables you have to be sure to set the 'Context' property, so for example '//localhost:FlowService/FlowService' in my case.

Message 7 of 13
(4,488 Views)

You can specify the context of an LNA thorugh an accessor, and then include the context in your URL, as per MartinMcD's answer.

0 Kudos
Message 8 of 13
(4,488 Views)

Thanks MartinMcD

I have to notice that my version of Linked Network Actor does not have a 'Context' property, even less an accessor.  So if I add a context property I would have to figure out where its applied.

Is there a different version of Linked Network Actor that I should be using for this?

Thanks!

-Sean

0 Kudos
Message 9 of 13
(4,488 Views)

I'm using version 1.2.0.19 which is available on the LNA page https://decibel.ni.com/content/docs/DOC-24051.

You set it using the Context accessor and then using the format '\\llocalhost:<Context>\<name>' in Connect.vi, as in my picture.

This link explains the necessity for the context when you're connecting multiple executables on the same PC:

http://zone.ni.com/reference/en-XX/help/371361H-01/lvconcepts/endpointurls/#advanced

0 Kudos
Message 10 of 13
(4,488 Views)