09-25-2018 05:59 AM
In my application I want to show an extra icon in the window taskbar at runtime when the front panel of a certain subvi is shown. In practice this subvi is a state machine that is started at the start of the main via the "Open vi Reference Function" and the Invoke node Run VI. At some point during the execution of the main the front panel of the subvi is shown. At that point I want an extra icon (more specific the subvi's Icon) in the taskbar at runtime.
At the moment all my dependencies are build into one executable. Should I change something at that level or is there a possibility to realize this functionality in the code using vi ref property/invoke nodes maybe?
09-25-2018 06:33 AM
09-25-2018 06:53 AM - edited 09-25-2018 07:06 AM
I am afraid this will not work for my program. The user will open the subvi front panel in the main. The main adds a cluster of information to a queue that is needed and dequeued in the subvi. When the user finishes its activity in the subvi, the subvis front panel is closed again and an event is triggered and processed by the main. (I use an EndevoGOOP400 Active object). Is there a way to parse these in- and outputs using System Exec? Or maybe I can create something like this with Asynchronous call of the Objects constructor?
By the way, the user has to be able to use the Main too while working in the subvi. That's why I choose to create an active object class. I want the icon so the user can see the subvi is still open even if it hidden behind the Main front panel. I would have possibly chosen for a modal vi if the user had to finish his actions in the subvi before entering the Main again, but that is not the case.
09-25-2018 07:15 AM
09-25-2018 07:32 AM - edited 09-25-2018 07:35 AM
OK, now we were entering unknown territory for me. You mean replacing my current Queue handler by functions from the 'Network streams functions'? Can I trigger events in the main from the subvi that way?
From a quick look it seems an alternative queued message handler. At the moment I create a user event in the Objects constructor and read and register in the main to be processed in an event structure. With a queue I suppose I have to let the main's event structure timeout instantly to check whether there is a message in the Network stream?
At the moment the program is located on our netwerk and various users may open the executable at the same time. Can that cause problems using this method?
09-25-2018 07:49 AM
Hi BdeBruin,
You mean replacing my current Queue handler by functions from the 'Network streams functions'?
You can also use plain UDP or TCP functions.
There also is a STM library at VIPM.
Can I trigger events in the main from the subvi that way?
Your receiver in the main can trigger events once it gets a message from your "subVI".
At the moment the program is located on our netwerk and various users may open the executable at the same time. Can that cause problems using this method?
As long as your executables only use the "localhost" for network communication they will not interfere with other user's computer…
09-25-2018 08:24 AM - edited 09-25-2018 08:25 AM
Thanks, it is clear for me so far. I will try to implement this and will keep this topic up to date.
09-25-2018 10:19 AM
You can also use the attached. It is a network queue that is a drop in replacement for the current Queue VIs.
09-28-2018 03:35 AM
Thanks, but I seesm to miss some vi in the vi.lib.
Instead I tried using the package here, also attached below. This work fine in the development environment. It also works fine as executable with the remote system as vi in the tester application. But when I build the remote separately and call it through System_exec it gives me error 314350 Create stream writer in the remote application, even with all firewalls are turned off.