06-25-2024 09:06 AM
@altenbach I did see your example, question is, would you suggest using a sub panel to display the clicked button? I don't want to run all the sub VIs at the same time, I want to only run the one that I click on, more like a state machine, and stop that specific SubVI as soon as I press another button, or stop.
06-25-2024 09:21 AM
Yes, it would be trivial to adapt so it changes the panel VI whenever the radiobutton changes. Similarly, you can di the same using a listbox.
06-26-2024 01:15 AM
Hi @Altenbach,
I honestly have trouble to implement the idea in labview. I will try to explain my problem more in details:
I have several (at the moment 17, I might need to add some in the future, but not regularly, so adding manually is not a problem) subVIs, which can run independently. The whole program is quite large, and constantly reading data from SQL, so I want to be able to run ONLY the clicked/chosen subVI, one at a time, and close the last open. How can I use a listbox, and how can I load my subVI by clicking on a cell on the listbox? which property nodes can I use to close the last panel and open the recently clicked? Is there a better way to close a subpanel, rather than abort?
would you be able to maybe attach a small sample VI?
I would really appreciate your help.
06-26-2024 10:03 AM - edited 06-26-2024 10:32 AM
Here's is a very quick simulation that shows the main logic.
(Note that I just changed the original attachment, so re-download)
06-26-2024 10:52 AM
Thank you so much! I really appreciate your solution.
06-26-2024 11:17 AM
Of course you could even use a value change on the listbox instead of a double-click for an even fast response, but it is easier to trigger by accident. Note that the listbox is configured to select 0 or 1 element.
07-04-2024 04:00 AM
I have implemented this solution and I can open my VIs in the subpanel, but I have a problem: all the VIs have multiple MCLBs which are interactive and connected to each other, but they are not reacting to anything! any Ideas?
e.g.: there are buttons to delete, rename, edit the entries. When pressed, nothing happens. A superior MCLB has some entries assigned to each element of it, which should appear in the subordinate MCLB, but it does not. Search boxes don't work either. The same VIs work perfectly individual.
07-04-2024 09:51 AM
07-05-2024 02:05 AM
Sorry for the abbreviations and unclear explanations. Here is the story:
I am loading data from live sql database. (hense, unfortunately cannot upload my files and code, they won't work without the database). I have several VIs, which have multiple multi column listboxes (MCLB). I am trying to build a top level VI to list and insert them individually for the user to choose for different puposes.
As an example, in my Tests.vi VI, I have a MCLB which is listing the test names (temperature, optic, relais test...), have a second MCLB which is listing the steps of the particular test clicked in MCLB1, [this is my superior MCLB], (e.g. temperature test: 4 steps of 1.initial measurement, 2.during test, 3.at the end, 4. after 5 min, Optic test:1 step) then I have a third MCLB which lists the type of the result one is expecting from that particular test clicked in MCLB1 (temperature: numeric, optic:passed/failed.) all of these data are populated in the MCLBs by SQL queries. When I click on the temperature in my MCLB1, it must highlight and list the steps in MCLB2, and also show the type of expected results in MCLB3.
At the moment, when I insert it in the top level VI, this is not happening. I see the MCLBs with the initial data loaded, but it seems like a static table.
The inserted VIs all work perfectly fine as a standalone, but when I insert them in this architecture, they are not reacting.
with superior I mean the first MCLB which has the entries to be selected, and with subordinate I mean the MCLBs which must react to the selected entry in the first MCLB.
I also have buttons to insert new test or test steps, to delete or rename them. The buttons don't work either.
I have attached a screenshot of my Tests.vi , but as I said, it works perfectly fine without inserting. I must mention there are more functions and MCLBs in this VI, I was just explaining an example.
07-05-2024 09:04 AM
(Maybe you could attach a much simplified version where the database IO is replaced by a simple simulation (e.g. a map with a queries as key and responses as values)
Your image does not contain the gist of the story, for example we don't see where you define the listbox items.
There are a lot of subVIs that I don't recognize.
Why do you use a mouse-up event instead of e.g. value change? Seems convoluted. The ctrlref of your event is guaranteed to be always the same and is not that interesting. It would seem more interesting to get and process the value of the listbox.