04-01-2014 10:09 AM
Hi
My application allows users to load one of several VIs in a subpanel.Each VI disolaying a part of system. The user enters the name of the required VI and by pressing Return or Enter(Num Pad) the VI is loaded. I want to add a feature thst allows user to go back and forth between these loaded VIs. I am trying to write unique index of every VI in an array within the same event handler. I am using feedback but the array is rewritten with every key event i.e.only the index of the currently oaded VI is written to the array at 0 index. This is confusing as paths, refnum etc. are passed on to the next iteration (of while loop) just fine using shift registers
Any suggestion would be welcome
Solved! Go to Solution.
04-01-2014 10:11 AM
I suggest posting code.
I think I know what you are doing and I think I have something in mind. An easy way is to just keep the last VI ref open and keep it in a shift register, and if the user presses undo or back or what ever, then reinsert it.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
04-01-2014 10:14 AM
Thanks for the reply. There are around 12 VIs plus user generated displays so keeping refnums open may not work.
04-01-2014 12:31 PM
@Nustian wrote:
Thanks for the reply. There are around 12 VIs plus user generated displays so keeping refnums open may not work.
Why would that not work because you have 12 VIs? If you wanted to have a full history to undo then sure you need to limit it somewhere, but how far back do you need to let them go? No undo on any program is limitless in size.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
17 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord
04-01-2014 05:08 PM
As i understand it, you can have some or all running, regardless if you're looking at them or not, so i'd say the easiest solution is to build an array of vi refs (which is easily done in the init step through vi-ref constants) and use a Ring control with names. On the value change event on the control, empty subpanel and insert new ref.
/Y
04-02-2014 06:54 AM
Thanks. Very helpful
04-02-2014 06:54 AM
Thanks. Very helpful