Module Tab - Edit LabWindows/CVI Module Call Dialog Box

Module Tab

You can use the Module tab to specify the function prototype, which includes the data type of each parameter and the values to pass for each parameter. The Parameters Table control shows all the available parameters for the function call and an entry for the return value. You can insert, remove, or rearrange the order of the parameters.

The Module tab contains the following options:

  • Module Pathname —The pathname of the code module file that contains the function the step calls. You can specify an absolute or relative pathname for the module file. Relative pathnames are relative to the TestStand search directory paths. Use the Edit Search Directories dialog box to customize the search directory paths .If you select a debug .dll built by LabWindows CVI 2019 or later, then the CVI Project File to Open on the Source Code Tab updates to the LabWindows/CVI .prj file that was used to build the selected .dll .
  • Function Name —Selects the function in the code module the step calls. The LabWindows/CVI Adapter attempts to read the code module file and find the names of all functions. If the code module type is not a C source file, the LabWindows/CVI Adapter populates the Function Name ring control with the names of all the functions the code module contains.If you select a debug .dll built by LabWindows/CVI 2019 or later as the Module, then the Source File that Contains Function on the Source Code Tab updates to the .c file path that was used to build the .dll .
  • Reload Prototype —Requests that the LabWindows/CVI Adapter query the code module for prototype information for the currently selected function. When a DLL contains export information or a type library or there is a type library with the same name as the DLL file and the function is defined in the type library, TestStand uses the prototype.
    Note If you create a DLL using LabWindows/CVI 7.1 or later, TestStand can read the prototype information for the currently selected function without the use of a type library.
    If the code module is a debug .dll built by LabWindows/CVI 2019 or later, then the CVI Project File to Open and the Source File that Contains Function on the Source Code Tab updates to the LabWindows/CVI .prj and .c that were used to build the .dll .
  • Edit Prototype —Displays the function prototype for editing. The LabWindows/CVI Adapter disables this control when it reads a function prototype from the code module.
  • Always Run In Process —Specifies whether the step always runs in-process even when the LabWindows/CVI Adapter is configured to run out-of-process. Use this option when you do not want the global settings for the adapter to affect the tools and step types you create for use with the LabWindows/CVI Adapter.
  • Parameters Table —Shows all of the available parameters for the function call and an entry for the return value. The Parameters Table control contains the following columns:
    • Name —A symbolic name for the parameter.
      Note Parameters with attributes include an Edit Attributes button in the Name column of the Parameters Table. TestStand associates parameter attributes with the module parameter, which TestStand stores with the step configuration information, not with the parameter value that TestStand passes to the module. Right-click an item in the Parameters Table to access the Parameters Table context menu, from which you can launch the Attributes dialog box.
    • Description —The short description of the parameter type using ANSI C syntax.
    • Log —When you enable this option, the step logs the parameter as an additional result. Enabling this option is equivalent to using the checkbox next to the additional result name in the Additional Results dialog box. For in/out parameters, enabling this option enables the [In] parameter and the [Out] parameter in the Additional Results dialog box. This option is indeterminate for in/out parameters if you specify to log only the [In] parameter value or only the [Out] parameter value. If this option is indeterminate, a tooltip specifies whether the Additional Results dialog box specifies to log the [In] parameter value or the [Out] parameter value.
    • Value Expression —The argument expression to pass.
    When you select a parameter in the Parameters Table control, the Parameter Details Table control contains the specific details about the parameter. The data type (Numeric, String, Enumeration, Object, C Struct, or Array) determines the information required for a parameter. As an alternative to specifying the function name and the parameter values, you can use the Function Call control to directly edit the function name and all the function arguments at once. To insert or remove parameters, click New or Delete . To rearrange the parameter order, select the parameter you want to move and click Move Up or Move Down .
  • Parameter Details Table —The data type of each parameter and additional information according to each parameter type. The Category ring control specifies a group of data types to list in the Type ring control. The categories include: Numeric , String , Enumeration , Object , C Struct , Arrays , TestData , TestError , and Pointer/Handle . The Type control specifies the data type of the function parameter.
    Note The LabWindows/CVI Adapter supports numeric return values, which includes Boolean, void*, and void.
  • Prototype —The prototype of the specified function in C syntax.
  • Create 2.0 Prototype —Discards the current parameters and values in the Parameters Table control and replaces the prototype with the TestStand 2.0. x standard prototype.
  • Function Call —Directly edits the function name and all of function arguments at once.

Editing the Function Call

You can use various controls in the Module tab to edit the function name and the argument values of the function. Alternatively, you can use the Function Call control to directly edit the function name and all of the function arguments at once. In the Function Call control, edit the call just as you would in a source code editor. If you enter a number of arguments different than the function prototype specifies, TestStand launches the Prototypes Conflict dialog box, in which you can alter the prototype to match the number of arguments you specify.

When you edit a call in the Function Call control, the Browse , Revert , Accept , or Go to Error buttons are visible. All other controls are dimmed.

  • Browse —Inserts variables, properties, or expression operators into the Function Call control.
  • Revert —Discards the changes you make in the Function Call control.
  • Accept —Applies the changes you made in the Function Call control.
  • Go to Error —Shows the highlighted syntax errors in the Function Call control.

See Also

Additional Results dialog box

Attributes dialog box

Edit Search Directories dialog box

Expression Operators

Locating the Correct DLL in 32-bit TestStand and 64-bit TestStand

Parameters Table Context Menu for Specify Module Dialog Boxes

Prototypes Conflict dialog box

Using Side-by-Side Versions of the LabWindows/CVI Run-Time Engine with TestStand

Using the $(Platform) Path Macro to Locate the Correct Code Module in 32-bit TestStand and 64-bit TestStand