UIMessageCodes Enumeration

TestStand 2017 Help

Edition Date: November 2017

Part Number: 370052W-01

»View Product Info

Download Help (Windows Only)
NI TestStand 2014 Help
NI TestStand 2014 SP1 Help
TestStand 2016 Help
TestStand 2016 SP1 Help
TestStand 2017 Help

Use these constants for the eventCode parameter of the Thread.PostUIMessageEx and Engine.PostUIMessage methods. These methods allow you to pass data with the message using the numericDataParam, stringDataParam, and activeXDataParam parameters.

Note  A user interface can respond to ModelState messages by displaying a label that describes the current state of the testing process.

  • UIMsg_AbortingExecution–(Value: 6) TestStand posts this message just before aborting an execution. TestStand does not actually abort execution until the user interface releases the UIMessage.
  • UIMsg_BreakOnBreakpoint–(Value: 2) TestStand posts this message to the user interface to notify it that the execution has suspended. The user interface must update the display accordingly.
  • UIMsg_BreakOnRunTimeError–(Value: 3) TestStand posts this message to the user interface to notify it that a run-time error has been encountered in the execution. The user interface must update the display accordingly.
    Note  The engine posts this event only when you select Show Dialog from the On Run-Time Error ring control on the Execution tab of the Station Options dialog box. A user interface typically calls the Engine.DisplayRunTimeErrorDialogEx method.
  • UIMsg_BreakOnUserRequest–(Value: 1) TestStand posts this message to the user interface to notify it that the execution suspended in response to a user request. The user interface must update the display accordingly.
  • UIMsg_CascadeWindows–(Value: 24) Post this message to the user interface to instruct it to cascade the windows the activeXDataParam parameter specifies. Use an array of ActiveX reference objects that reference a PropertyObjectFile or an Execution for the activeXDataParam parameter. The user interface cascades the windows that correspond to the objects in the array. To cascade all windows, pass a NULL reference for the activeXDataParam parameter or use the Nothing keyword if you are using the ActiveX/COM Adapter.
  • UIMsg_ClientFileChanged–(Value: 28) An Execution object posts this message when a client changes the value of the Execution.ClientFile property. The UIMessage.Execution property references the Execution that sends the message.
  • UIMsg_CloseWindows–(Value: 26) Post this message to the user interface to instruct it to close a window or windows that display a PropertyObjectFile or an execution. Specify the window by passing a PropertyObjectFile or Execution reference for the activeXDataParam parameter, or specify several windows by passing an ActiveX reference array of such objects for the activeXDataParam parameter. Pass a NULL reference, or use the Nothing keyword if you are using the ActiveX/COM Adapter, to close all currently open document windows in the user interface.
  • UIMsg_DisplayReport–(Value: 29) Post this message when you want the user interface to display the current contents of the execution report.
  • UIMsg_EndExecution–(Value: 8) TestStand posts this message after an execution completes. The user interface must update the display accordingly.
  • UIMsg_EndFileExecution–(Value: 19) TestStand posts this message when the execution finishes using a sequence file. TestStand specifies the file in the UIMessage.ActiveXData property.
  • UIMsg_EndInteractiveExecution–(Value: 14) TestStand posts this message whenever an interactive execution ends.
  • UIMsg_GotoLocation–(Value: 38) The Locations.GotoLocation method posts this message to the user interface to instruct the user interface to select the Locations passed in as the activeXDataParam parameter.
  • UIMsg_KillingExecutionThreads–(Value: 7) TestStand posts this message just before killing the threads in an execution. TestStand does not actually kill the threads until the user interface releases the UIMessage.
  • UIMsg_LocalizationSettingChanged–(Value: 21) TestStand posts this message to notify the user interface that the decimal point localization setting has changed in the system setting for the operating system or in the StationOptions.UseLocalizedDecimalPoint setting. When a user interface receives this message, it should refresh any values it displays that these changes might affect.
  • UIMsg_ModelState_BeginTesting–(Value: 33) TestStand process models post this message to the user interface prior to calling MainSequence in the client sequence file. The numericDataParam parameter specifies the test-socket index. The activeXDataParam parameter contains a reference to the sequence context for the process model sequence file that posts the message.
  • UIMsg_ModelState_EnabledStateSet–(Value: 36) TestStand Batch process models post this message to the user interface after setting the enabled state of a test-socket execution. The value of the stringDataParam parameter is True if the socket is enabled and False if the socket is disabled. The numericDataParam parameter specifies the test-socket index. The activeXDataParam parameter contains a reference to the sequence context for the process model sequence file that posts the message.
  • UIMsg_ModelState_Identified–(Value: 32) TestStand process models post this message to the user interface after identifying the serial number for a unit under test (UUT) or batch of UUTs. The stringDataParam parameter specifies the UUT serial number unless the execution is a batch controller. If the execution is a batch controller, the stringDataParam parameter specifies the batch serial number. The numericDataParam parameter specifies the test-socket index. The activeXDataParam parameter contains a reference to the sequence context for the process model sequence file that posts the message.
  • UIMsg_ModelState_Initializing–(Value: 30) TestStand process models post this message to the user interface before performing initialization prior to testing. The numericDataParam parameter specifies the test-socket index. The activeXDataParam parameter contains a reference to the sequence context for the process model sequence file that posts the message.
  • UIMsg_ModelState_PostProcessing–(Value: 43) TestStand process models post this message to the user interface before generating the report and logging the data for a client sequence file. The numericDataParam parameter specifies the test-socket index. The activeXDataParam parameter contains a reference to the sequence context for the process model sequence file that posts the message.
  • UIMsg_ModelState_PostProcessingComplete–(Value: 35) TestStand process models post this message to the user interface after generating the report and logging the data for a client sequence file. The numericDataParam parameter specifies the test-socket index. The activeXDataParam parameter contains a reference to the sequence context for the process model sequence file that posts the message.
  • UIMsg_ModelState_TestingComplete–(Value: 34) TestStand process models post this message to the user interface after the MainSequence in the client sequence file returns control to the model. If the execution is not a batch controller or a parallel controller, the stringDataParam parameter specifies the UUT result status. If the execution is a batch controller or a parallel controller, the value of the stringDataParam parameter specifies the overall status of the controlling execution, which by default can be Passed, Failed, Error, Terminated, or Aborted. The numericDataParam parameter specifies the test-socket index. The activeXDataParam parameter contains a reference to the sequence context for the process model sequence file that posts the message.
  • UIMsg_ModelState_Waiting–(Value: 31) TestStand process models post this message to the user interface before waiting for an action to occur, such as the user entering a serial number in response to a prompt. The numericDataParam parameter specifies the test-socket index. The activeXDataParam parameter contains a reference to the sequence context for the process model sequence file that posts the message.
  • UIMsg_NonTerminatableThreadsArePreventingTermination–(Value: 42) An execution posts this message when it attempts to terminate and every thread in the execution uses a value of ThreadTerminationOptions_Prompt for the Thread.TerminationOption property. A user interface typically handles this event by prompting users to terminate all threads. If the user chooses to terminate all threads, the user interface calls the Execution.OverrideNonTerminatableThreads property to signal the threads that use a value of ThreadTerminationOptions_Prompt for the Thread.TerminationOption property to stop running.
  • UIMsg_OpenWindows–(Value: 22) Post this message to the user interface to instruct it to open a file in a window. If the file or execution is already open, the application brings the file to the front. A file can be specified by a pathname in the stringDataParam parameter or by a PropertyObjectFile object in the activeXDataParam parameter. An execution can be specified by an Execution object in the activeXDataParam parameter. A list of files and/or executions can be specified by an array of references to PropertyObjectFile and Execution objects in the activeXDataParam parameter. For sequence files, the stringDataParam parameter can also contain a '|' separator followed by the name of a sequence to display. If you specify the sequence file in the activeXDataParam parameter, you can specify just the sequence name in the stringDataParam parameter. This constant does not support opening workspace files.
  • UIMsg_OutputMessages–(Value: 40) TestStand posts this message at periodic intervals when it holds references to output messages that calls to the OutputMessage.Post method queue. TestStand transfers the queued messages to an OutputMessages collection attached to the UIMessage.ActiveXData property for this event. Ensure that an application that processes output messages copies the output message references from the collection in UIMessage.ActiveXData to a private OutputMessages collection by passing the private collection to the OutputMessages.CopyMessagesToCollection method. An application calls the Engine.NewOutputMessages method to create a private OutputMessage collection. TestStand generates this event only if the Engine.OutputMessagesEnabled property is True. Because there can be more than one handler for this event, ensure that the application does not modify the OutputMessages collection the UIMessage.ActiveXData property holds.
  • UIMsg_ProgressPercent–(Value: 11) TestStand step modules post this message to the user interface to notify it to update the progress indicator associated with an execution. The activeXDataParam parameter specifies an execution. The numericDataParam parameter specifies a value from 0 to 100 that indicates the percentage of progress the current execution reports. This value indicates the progress of operations for which the execution chooses to report the amount of progress. The value does not necessarily reflect the progress of the execution as a whole.
  • UIMsg_ProgressText–(Value: 12) TestStand step modules post this message to the user interface to notify it to update the progress message associated with an execution. The activeXDataParam parameter specifies an execution. The stringDataParam parameter specifies a progress message.
  • UIMsg_PushUndoItem–(Value: 39) Post this message to the sequence editor to instruct the sequence editor to push an undo item onto an UndoStack. An undo item is a COM object that implements the UndoItem interface. You pass the undo item as the activeXDataParam parameter. The sequence editor uses the UndoItem.EditedFile property to determine which UndoStack to push the undo item onto. Send this message synchronously to determine which UndoStack the sequence editor placed the undo item onto immediately after the call to the PostUIMessage method returns by checking the UndoItem.UndoStack property.
  • UIMsg_RefreshWindows–(Value: 27) Post this message to the user interface to instruct it to refresh the data it displays for the corresponding PropertyObjectFile or SequenceContext you pass for the activeXDataParam parameter. Pass a single reference or an ActiveX array of references using the activeXDataParam parameter to specify which window or windows to refresh. Pass a SequenceContext object to refresh the values for the steps which the user interface displays for that execution. Pass NULL for the activeXDataParam parameter to refresh the displays for all the files and executions. The Overriding SequenceFilePostStepFailure Callback and the Overriding SequenceFilePostStepRuntimeError Callback examples located in the <TestStand Public>\Examples\Modifying Process Models\Overriding Engine Callbacks directory demonstrate how to use this UIMessage.
  • UIMsg_ReportChanged–(Value: 25) The TestStand Engine posts this message to the user interface whenever you update the report of an execution. This allows the user interface to refresh the Report view if it is showing.
  • UIMsg_ReportCollectionChanged–(Value: 44) The TestStand Engine posts this message when the content or an active report changes for the Reports collection of an execution. If the active report changes, the activeXDataParam parameter contains a reference to the previously active report.
  • UIMsg_ReportLocationChanged–(Value: 37) The TestStand Engine posts this message to the user interface whenever you change the location of the report.
  • UIMsg_ResumeFromBreak–(Value: 17) TestStand posts this message when an execution resumes after being suspended at a breakpoint. The execution resumes when the user interface message is released.
  • UIMsg_RuntimeError–(Value: 45) TestStand posts this message to the user interface to notify the user interface that the execution has encountered a run-time error. The user interface can alter the error, for example, by adding contextual information to the error message.
  • UIMsg_ShutDownCancelled–(Value: 20) TestStand posts this message to notify the user interface that the user cancelled a pending shutdown.
  • UIMsg_ShutDownComplete–(Value: 9) TestStand posts this message when a shutdown completes. If this is not the final shutdown, the user interface can continue to load and execute sequences.
  • UIMsg_StartExecution–(Value: 10) TestStand posts this message when an execution begins. This message serves to notify the user interface to update the display accordingly.
  • UIMsg_StartFileExecution–(Value: 18) TestStand posts this message when it begins using a sequence file. TestStand specifies the file in the UIMessage.ActiveXData property.
  • UIMsg_StartInteractiveExecution–(Value: 13) TestStand posts this message whenever an interactive execution begins.
  • UIMsg_TerminatingExecution–(Value: 5) TestStand posts this message just before terminating an execution. The execution does not actually terminate until the user interface releases the UIMessage.
  • UIMsg_TerminatingInteractiveExecution–(Value: 15) TestStand posts this message just before terminating an interactive execution. The interactive execution does not actually terminate until the user interface message is released.
  • UIMsg_TerminationCancelled–(Value: 16) TestStand posts this message to notify the user interface to update the display when a pending termination is cancelled.
  • UIMsg_TileWindows–(Value: 23) Post this message to the user interface to instruct it to tile the windows the activeXDataParam parameter specifies. Use an array of ActiveX reference objects that reference a PropertyObjectFile or an Execution for the activeXDataParam parameter. The user interface tiles the windows that correspond to the objects in the array. To tile all windows, pass a NULL reference for the activeXDataParam parameter or use the Nothing keyword if you are using the ActiveX/COM Adapter.
  • UIMsg_Trace–(Value: 4) TestStand posts this message to the user interface to notify it that the execution has reached a trace point. The user interface must update the display accordingly.
  • UIMsg_TypePaletteFileListChanged–(Value: 41) TestStand posts this message to the user interface to notify it that the type palette file list has changed. The user interface must update its display accordingly. This event occurs after calling the Engine.UnloadTypePaletteFiles, Engine.LoadTypePaletteFilesEx, and Engine.SetTypePaletteFileList methods.
  • UIMsg_UserMessageBase–(Value: 10000) Codes for all user-defined messages must be greater than or equal to the value of this constant. Define and use event codes greater than UIMsg_UserMessageBase only when you can ensure that the event code does not conflict with event codes for messages that other custom TestStand components, such as add-on products, define. National Instruments recommends using the Engine.RegisterUIMessage method to obtain an event code for a message to guarantee that the code is unique for the lifetime of the engine. Components that generate and process the message call this method, which returns the previously assigned message code if the message is already assigned.

See Also

Engine.DisplayRunTimeErrorDialogEx

Engine.GetOutputMessages

Engine.NewOutputMessages

Engine.OutputMessagesEnabled

Engine.PostUIMessage

Engine.Shutdown

Execution tab

Execution.ClientFile

Locations.GotoLocation

OutputMessage.Post

OutputMessages

OutputMessages.CopyMessagesToCollection

OutputMessages.TransferMessagesToCollection

Station Options dialog box

Thread.PostUIMessageEx

UIMessage

UIMessage.ActiveXData

UIMessage.Event

UIMessage.Execution

UndoItem

UndoItem.EditedFile

UndoItem.UndoStack

WAS THIS ARTICLE HELPFUL?

Not Helpful