From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
06-30-2014 05:18 AM
Hi everybody,
in a part of my program there are two numeric controls inside a while loop (while all values are selected, user hits stop). The loop is activated in a tab of my tab control, but controls are in another tab.
When the loop starts it's impossible for me to change from a tab to another, although I've placed the tab contol inside the while loop. The problem is that the tab wich I'm locked in is not the tab with control and stop buttons !
Any ideas ?
Thanks in advance
Solved! Go to Solution.
06-30-2014 05:29 AM - edited 06-30-2014 05:30 AM
It'll be helpful if you upload your VI for people to look at.
Two (simple) causes of not being able to switch tabs.
I would also recommend - if you haven't done this already - ensuring you have placed a wait function in your while loop so that it doesn't hog CPU.
06-30-2014 05:36 AM
@Potterton wrote:
It'll be helpful if you upload your VI for people to look at.
Two (simple) causes of not being able to switch tabs.
- Your tab is an indicator not a control. Fix by right clicking tab and selecting switch to control.
- One of the tab's pages is locked. Fix by right clicking tab page and selecting Advance> Page enabled state> Enabled
I would also recommend - if you haven't done this already - ensuring you have placed a wait function in your while loop so that it doesn't hog CPU.
Very good guess.
06-30-2014 09:18 AM
Thanks for the answer. My Tab control is not an indicator and has no pages locked, added the wait function in while loop, but was not helpful ....
The test of this vi is a little complicated: I post here a llb. The vi to open is Imaging2.vi, other files are subVis. Unpack the archive data.rar, it contains datas to test the software.
Open Imaging2.vi and select the folder where you unpacked data.rar, using the path <where u unpacked>\data\analisiPicchi, and selecting 4 in 'passi per lato' control.
Run the vi, and go to 'Imaging' tab, then open on the right the 'investigate pixel' tab, and modify one of the coordinates (for example X). Hit ok on the dialog box wich opens, and then try to change tab. I experienced all the panel locked.
Are u experiencing same issue ?
Thaks for the help
06-30-2014 09:18 AM
sorry, forgot llb
06-30-2014 11:20 AM
Ahh, I didn't realise the tab control was in an event structure. Your 'Y' value event change structure is set to 'lock panel' - so you can't do anything until that event has completed, which it can't because you're stuck in a loop.
Fix it by right clicking the "X", "Y" value change event, selecting the "Y" event and unticking the 'lock panel' check box.
Also, an FYI: if you right click your filepath control and select 'Browse options...' you can change to folder selection mode.
And not be too disparaging, but your VI is really bloody messy - your future self will thank you if you keep it tidier.
06-30-2014 12:14 PM
@Potterton wrote:
And not be too disparaging, but your VI is really bloody messy - your future self will thank you if you keep it tidier.
I always liken this to writing text code with random indents. It will still run, but you'll be pulling your hair out trying to figure out how the code runs.
07-01-2014 02:53 AM - edited 07-01-2014 02:54 AM
Thanks for hits, I thoght that the lock panel option was for all the event instead of just the X value change
In future I'll write more ordinated Vi !