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.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

How to add filter in SequenceFilePostStep for steptype .Net?

Hello,

how can i add an if statement in SequenceFilePostStep that gets only true if the Step was a .Net step?

And another file that only executes if the filename equals "abc"?

 

Thanks

0 Kudos
Message 1 of 6
(2,139 Views)

For the Adapter you can use: Parameters.Step.AdapterKeyName == "DotNet Adapter"

 

Not sure what you mean by your second question.  Can you shed some more clarification on it?

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
0 Kudos
Message 2 of 6
(2,136 Views)

I don´t have Parameters.Step.AdapterKeyName?

 

 

Oh, i meant "filter" not "file".

I want to create an if that checks the filename.

 

For example:

myfile.seq contains a some steps.

The model sequence has a SequenceFilePostStep.

In here i want to check "if" the file equals "myfile.seq".

0 Kudos
Message 3 of 6
(2,130 Views)

Just to clarify SequenceFilePostStep callback will only ever be called by the file within which it exists.  ProcessModelPostStep Callback will/can be called by any client sequence file and can only exist in a file marked as a Model.

 

I'll assume you are referring to ProcessModelPostStep callback.  The verbiage you want is: RunState.Caller.SequenceFile.AsPropertyObjectFile.DisplayName == "myfile.seq"

 

Hope this helps,

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
Message 4 of 6
(2,121 Views)

Perfect. Exactly what i was serching for.

 

Where can find a documentation of all the callbacks?

When searching in Teststand Help for "ProcessModelPostStep " i get 0 results.

0 Kudos
Message 5 of 6
(2,110 Views)

Engine Callbacks are here:

https://zone.ni.com/reference/en-XX/help/370052R-01/tsfundamentals/infotopics/callbacks_engine_list/

High level view of callbacks in general:

https://zone.ni.com/reference/en-XX/help/370052R-01/tsfundamentals/infotopics/bldgblocks_callbackseq...

 

Look in the process model for Model Callbacks.

 

Hope this helps,

 

 

jigg
CTA, CLA
testeract.com
~Will work for kudos and/or BBQ~
0 Kudos
Message 6 of 6
(2,103 Views)