Academic Company Events Community Support Solutions Products & Services Contact NI MyNI
This Document is not yet Rated

How do I Programmatically Insert a Custom Step Type into a TestStand Sequence Using the OnNewStep Custom Substep?

Primary Software:
Primary Software Version: 3.1
Primary Software Fixed Version: N/A
Secondary Software: LabVIEW Development Systems>>LabVIEW Full Development System


I need to programmatically insert a custom step type into a sequence using the OnNewStep custom substep. If I manually drag and drop the custom step type from the Insertion Palette, a new custom step is created as expected. However, if I try to insert the step programmatically, TestStand inserts the custom step but it does not include the appropriate module information defined in my type definition. If I right-click the step and select specify module, everything is empty. How can I obtain the same behavior programmatically that I have manually?


This behavior occurs when you attempt to programmatically insert a step that has a default module defined in its type definition.  When you programmatically create the step to insert into your sequence, you have to specify a value for the adapterKeyName parameter of the Engine.NewStep method which represents the adapter that will be used to call the step's module.  When you specify a value for this parameter, the method overrides the default module information that you have designated in the type's definition and assumes a blank module of the adapter defined by the value of this parameter.

In order to retain your default module information as it is defined in the definition of the step type, use an empty string for the for the adapterKeyName parameter value.  For more information, use the related link for the NI TestStand Help.

For assistance creating a new step programmatically and inserting it into a sequence, view the NI Developer Zone document Programmatically Inserting a Step into a TestStand Sequence Using LabVIEW..

Related Links:
Programmatically Inserting a Step into a TestStand Sequence Using LabVIEW
NI TestStand Help: Engine.NewStep Method


Report Date: 03/23/2010
Last Updated: 03/26/2010
Document ID: 57MAKH46

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
  1 2 3 4 5
Please Contact NI for all product and support inquiries.submit