annuler
Affichage des résultats de 
Rechercher plutôt 
Vouliez-vous dire : 

Questions: calling vi dynamically using vi server

Résolu !
Accéder à la solution

I have a few questions on the following vi.

 

1. Is there a better way to determine at run time whether a vi is part of a build or not?

 

2. Is there a better way to pass values to a dynamically called vi.  Or better yet, a better way to call a vi dynamically?

 

3.  When I run the code as pictured above in a build the vi doesn't actually open. It opens fine when it's not a build.  However, when I call the vi dynamically, and enable the vi in the bottom right, 2 windows will pop up, the dynamic one and the other one.  Any clues as to what is happening here?

Message Edited by elset191 on 04-15-2009 03:59 PM
--
Tim Elsey
Certified LabVIEW Architect
0 Compliments
Message 1 sur 5
3 789 Visites
Solution
Accepté par elset191
Did you make sure your disabled VI is listed as VI to be included in the build specification?  If you didn't, when the VI is build into an .exe, the disable diagram block and the VI within it are probably being stripped from the .exe
Message 2 sur 5
3 779 Visites

That solved number 3. 

 

Are there any suggestions to clean up #1 or #2?

--
Tim Elsey
Certified LabVIEW Architect
0 Compliments
Message 3 sur 5
3 771 Visites

for #2.....

 

Use global variables to pass data dynamically .......

Anil Punnam
CLD
LV 2012, TestStand 4.2..........
0 Compliments
Message 4 sur 5
3 745 Visites

Anil Reddy wrote:

for #2.....

 

Use global variables to pass data dynamically .......


 

Rather than a global variable (shiver) I would use a queue to pass the parameters. A seperate queue for each created clone lets me interact with the deisred instance. Sans queues you would have to work out a handshaking mechanism to ensure the right values got sent to the right instance.

 

Short of that just using a single control that is a cluster with all of those values would let me do it with a single invoke node.

 

If all of those values are static, your way be OK except... the For Loop

 

 

Use a shift register for the error cluster so you do not loose errors reporting.

 

Ben

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 5 sur 5
3 728 Visites