03-04-2024 10:46 AM - edited 03-04-2024 10:50 AM
Hello,
So now the Vis are switching when i use the ring, but they are not running.
If i use a Run vi now it is not working. It shows nothing then...
03-04-2024 11:10 AM - edited 03-04-2024 11:12 AM
@Julsbng wrote:
Hello,
So now the Vis are switching when i use the ring, but they are not running.
If i use a Run vi now it is not working. It shows nothing then...
You need to remove, then reinsert on change, something like that:
03-04-2024 11:54 AM
Hello,
thank you i will try this.
You don’t have a connection to the N of the for loop, isn’t it needed or it won’t run?
03-04-2024 02:25 PM
Its working perfectly thank you very much.
But i still got one issue. The size of the front panels of the Vis are the same size as the subpanel but its not fitting correct when i start the programm. i need to adjust the subpanel with the slider so i can see the whole front panel and not some empty space. How can i fix this? I know that i can do some setting with window size etc but this didnt work maby i did somethign wrong. I will attach some pictures tomorrow.
Thank you very much for your help so far. !
best regards
03-04-2024 02:58 PM
@Julsbng wrote:
Its working perfectly thank you very much.
But i still got one issue. The size of the front panels of the Vis are the same size as the subpanel but its not fitting correct when i start the programm. i need to adjust the subpanel with the slider so i can see the whole front panel and not some empty space. How can i fix this?
The trick which I using time to time is to set properties as shown below:
Just set the size equal to the size of your subpanel, you will see gray border which can be used as guide to control that all UI elements placed on the BD are fit with visible area (this border will be not displayed in runtime). Don't forget to set Origin to 0,0 - this will move it to left upper corner and disable scrollbars if you don't need. That is.
03-05-2024 05:13 AM - edited 03-05-2024 05:24 AM
Hello, Thank you very much this is working aswell but i got a problem now that i expected to happen...
The Vis share similar output and so the DAQ is reserved when starting them simultaneously.
When i say stop, the one Vis is working but when i use the Switch to the other Vi its not running.
Any idea how to avoid this to happen?
I think in need to Start the applications one by one and quit the other before opening the new one.... but i dont know how to do this
03-05-2024 05:50 AM
I got it run now.
Thanks for all the help! Really appreciate.
03-05-2024 05:53 AM
Using Abort to stop a VI is like using a tree to stop the car. It works, but might have some consequences.
03-05-2024 05:55 AM
I would love to get a better solution here! I appreciate any tips to get better and improve.
03-05-2024 06:14 AM
You mentioned the two VI's use similar DAQ? I assume they don't use the same channels though, right? If so, you can create and start the DAQ task first in the main VI (that reads all channels) and just use the task in the two VI's and grab the relevant ones.
That way both subVIs can keep running even when they're not shown.
I'd also create a way of stopping the VI's gracefully. Send in (or obtain through name, it's less recommended but might fine in this case) a User event or queue so you can for starters signal a Shut down command, that way it can easily expand later on if you need more functionality.