Monitor Connection Status Flag for Database Logging in TestStand

Updated Nov 12, 2024

Environment

Software

  • TestStand

How can I monitor my connection status to a database in TestStand for logging purposes? 

 

At times it may be necessary to monitor the status of your connection to a database for result logging. You can monitor the connection through RunState.Sequence.Main["Log Results to Database"].Result.Status .

In the steps below we outline how a user can locate this flag in their own callback sequence. 

1. You will first need to edit the LogToDatabase callback sequence. Open a sequence file and right click on your Sequences pane. Select "Sequence File Callbacks...". You will see the following call back options. Select LogToDatabase and hit OK. 
Call Back
2.Once added, double click on the Sequence Call step of the LogToDatabase Callback. 
Log Results to Database Status 2.PNG

3.Expand your Variables pain in the following order: 
RunState > Sequence > Main > Log Results to Database > Result > Status
 

Here you will find the status string for the connection to your database for logging. 

Log Results to Database Status 4.PNG