LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I use tab control to sequence a test

I would like to use the tab control to sequence testing. Does anyone have an application that uses this method that I can use to make it work?

 

Regards

Conor

0 Kudos
Message 1 of 11
(3,930 Views)

Hi Conor,

can you give more information please? What shall the tab control do? You can use a queued state mashine. The the "Producer/Consumer desing pattern".

 

Hope it helps.

Mike

0 Kudos
Message 2 of 11
(3,927 Views)

Conor,

 

I once wrote a program that had four states: calibrate, collect, analyze and save.  I put each state with the relevent controls on seperate tabs.  To force the user to do the tests sequentially I hid the tabs and placed forward and reverse buttons below the tab control.

 

On the block diagram I used an event structure to respond to the forward/reverse buttons and a shift register to keep track of the current state.

 

Hope this is helpful.

Drog

0 Kudos
Message 3 of 11
(3,919 Views)

Hi Mike,

 

I want the tabs to show the full sequence of tests to do and then the current tab to show the current test with user intervention to allow one tab to finsh and the next one to start.

 

Regards

Conor

0 Kudos
Message 4 of 11
(3,901 Views)
Many thanks
0 Kudos
Message 5 of 11
(3,892 Views)
Why do you want tabs?  Do you have a lot of indicators and controls for each tab?  A simple state machine will execute your states in the order you want.  An indicator on the front panel can show which state is being executed.  What kind of user intervention do you want?  Will the user stop one state, restart, skip to the next, etc.?
- tbob

Inventor of the WORM Global
0 Kudos
Message 6 of 11
(3,853 Views)

Thanks for your reply. I have 6 different categories of tests that I need to have the user execute in sequence. Some require user intervention with fitting cables before contintinuing (for example) and others the user may not to ship or jump to for various reasons. I have a start condition where the user enters their ID and a serial number which is then check in a database. Tab control seemed to be a good way to manage this??

 

Regards

Conor

0 Kudos
Message 7 of 11
(3,841 Views)
I think a state machine would be your best bet for an architecture.  You can programatically define the next state.  If the type of test requires connecting cables or not connecting, you can put the dialog box in its own state.  Then in the state before, you decide by using a case structure if you want to call the dialog state or skip to the next.  See attached vi.
- tbob

Inventor of the WORM Global
0 Kudos
Message 8 of 11
(3,824 Views)

Many thanks for your reply. One of the things I want to do is have the user log in and then when their log in validated, to make the screen disappear and be replaced by a screen for each test category as they cycle through. One of the reasons for doing this is that each test category has about 20 test results each with their own pass/fail criteria. Is it possible to do this using the method you propose?

 

Regards

Conor

0 Kudos
Message 9 of 11
(3,809 Views)

Conor,

 

A state machine can certainly do the kinds of things you  request.  I concur with tbob that it is probably the  best architecture for what you have described.

 

I have written code implementing state machines which require logins and passwords.

 

Lynn 

0 Kudos
Message 10 of 11
(3,792 Views)