NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Checkbox Implimentation in TSOP

Hi ,
     I am new to TestStand Operator interface. My requirement is I have to impliment some check boxes in simple operator interface GUI, so that I can select individual tests instead of sequences. Please let me know whether is it possible with operator interface and if yes how? It would be highly appreciated for any helps.
0 Kudos
Message 1 of 9
(4,461 Views)
Using the full featured operator interfaces that are supplied with TS, you can hold down control and then select as many steps as you want.  Then right click on one of the highlighted steps and select "run selected steps".
 
If you want the check boxes specifically then you can modify one of the operator interfaces, written in a language your familiar with, that ships with TS.

Message Edited by Dillon G on 09-20-2007 05:32 PM

0 Kudos
Message 2 of 9
(4,437 Views)
Hello,

What do you mean by individual tests? Are you talking about individual steps or groups of steps that make up a specific test? In th OI you can right click any step and run just that step. You can also select (shift click or ctrl click) a group of steps and just run them by right-clicking and selecting the run selected steps.


Adam

National Instruments
Applications Engineer
0 Kudos
Message 3 of 9
(4,434 Views)
Thanks for your valuable answer...... Could you please tell me whether can I impliment the check box logic for selecting individual tests, not sequences with TestStand Operator Interface. The requirement I received is to impliment a GUI with check boxes to select individual tests. My concern is Operator interface code is using activeX controls callback.  Can I customize Operator Interface in CVI code Available with TestStand or do I write Operator Interface to satisfy my requirements? Any helps regarding implimentation would be highly appreciated.

Message Edited by 12345qwertt on 09-25-2007 04:09 PM

Message Edited by 12345qwertt on 09-25-2007 04:17 PM

0 Kudos
Message 4 of 9
(4,404 Views)

There is no option to make the SequenceView ActiveX control display checkmarks in the step list it displays. If you absolutely must have this, you'll need to write your own list box control to display the steps. Given how much the SequenceView ActiveX control provides, it would be a big undertaking to reimplement it for such a minor UI tweak. However, if you just want to display a list with checkboxes and don't need all the bells and whistles of the SequenceView, you could probably implement it yourself in a reasonable period. Perhaps you could put your own checkmarkable step list next to the existing sequence view and update the selected steps to match your checkmarks? It might even be possible to use the SequenceView HitTest, ItemIndexToStep, and StepToItemIndex functions to match up a parallel scrollable list of checkmarks to the steps in an SequenceView. I haven't tried to hack that one together, so I'm not sure that it is a good idea..

Prior to 4.0 we shipped example Operator Interfaces that did not use the ActiveX controls. Coincidentally, they included step list boxes with checkmarks (at least the CVI one did, I didn't try them all).  They were located in:

C:\Program Files\National Instruments\TestStand 3.5\OperatorInterfaces\NI\TestStand 2.0.1 Operator Interfaces (Old)\Full-Featured\

However, these examples are way more complicated and less functional than the new User Interfaces that use the ActiveX controls, so I highly recommend against basing a project on them unless they just happen to already do everything you will ever want in your Operator Interface application.

0 Kudos
Message 5 of 9
(4,386 Views)
Thanks alot for your detailed answer...... I have started iimenting TSOP without activeX controls callback functions. The problem I am facing now is when I am starting interactive execution, I am getting an error message as attached when execution reaches at TS_EngineNewExecution(). This is due to something wrong with CA_VariantLong() inside TS_EngineNewExecution(). I am placing my function below. I have hard coded interactive step index as 2.
 
void ExecuteSequence(char *sequenceName, VBOOL useProcessModel)
    {
    LPDISPATCH dispPtr;
    CAObjHandle sequenceArguments;
    ERRORINFO   errorInfo;
    int         error = 0;
    CAObjHandle modelSeqFile = 0;
 CAObjHandle newInteractiveArgs = 0;
    char *modelDesc = NULL;        
    if(gReport)
        {
        CA_DiscardObjHandle(gReport);
        gReport = 0;
       
        }      
    if(useProcessModel)
        oleErrChk( TS_SeqFileGetModelSeqFile (gCurrentSequenceFile, &errorInfo,
                                                 &modelDesc, &modelSeqFile));
 errChk(CreateSequenceParamPropObj (&sequenceArguments));
    errChk(CA_GetDispatchFromObjHandle (sequenceArguments, &dispPtr));
 
 TS_EngineNewInteractiveArgs (gEngine, &errorInfo, &newInteractiveArgs);
 TS_InteractiveArgsAddStepIndex (newInteractiveArgs, &errorInfo, 2);   
    oleErrChk( TS_EngineNewExecution (gEngine, &errorInfo, gCurrentSequenceFile,
                                      sequenceName, modelSeqFile, VFALSE,
                                      TS_ExecTypeMask_Normal, CA_VariantDispatch(dispPtr),
                                      CA_DEFAULT_VAL, CA_VariantLong(newInteractiveArgs),
                                      &gCurrentExecution));
 
 gSequenceState = Running;
    oleErrChk( TS_ExecutionGetProperty (gCurrentExecution, &errorInfo, TS_ExecutionId,
                                  CAVT_LONG, &gCurrentExecutionId));
Error:
    if(sequenceArguments)
        CA_DiscardObjHandle(sequenceArguments);
    if(modelSeqFile)
        CA_DiscardObjHandle(modelSeqFile);
    if(modelDesc)
        CA_FreeMemory(modelDesc);
    return;
    }
 
I didn't get a better solution from discussion forum to resolve the issue . Any help to resolve the issue would be highly appreciated.

Message Edited by 12345qwertt on 10-01-2007 01:31 PM

0 Kudos
Message 6 of 9
(4,342 Views)
I haven't tested this, but looking off the top of my head, you are passing the InteractiveArgs object handle in as a long, when you really need to pass it in as dispatch handle.  Call CA_GetDispatchFromObjHandle() on the newInteractiveArgs variable.  Pass the dispatch handle in using CA_VariantDispatch().

Allen P.
NI

0 Kudos
Message 7 of 9
(4,327 Views)
Thanks for your reply.....I am able to get rid of error displayed....But still I am suffering to execute step 2 alone. Interactive execution stops prematurely without executing step 2.

Message Edited by 12345qwertt on 10-01-2007 04:07 PM

0 Kudos
Message 8 of 9
(4,322 Views)
You don't seem to be setting the Sequence or StepGroup on your InteractiveArgs object.  This might be the cause.

Allen P.
NI
0 Kudos
Message 9 of 9
(4,309 Views)