NI TestStand

Showing results for 
Search instead for 
Did you mean: 

Dynamically changing the report path

Go to solution
Is there any way to dynamically change the path where the reports are saved. Teststand 4.1.1
Message Edited by glennjammin on 04-21-2010 03:30 PM
Glenn Ellis
0 Kudos
Message 1 of 7



Try RunState.Root.Locals.ReportFilePath


Hope this helps



Sessions NI-Week 2017 2016
Feedback or kudos are welcome
Message 2 of 7
Accepted by topic author glennjammin



You can set a specific report path for any sequence you run via the process model entry points using the ReportOptions Callback in your sequence. It will let you modify any of the current settings in the Report Options (including the path) for that sequence execution. This allows each of your sequences to have unique reporting options.


If I understand your question, what you want to do is exactly what the ReportOptions Callback is designed for.



Message 3 of 7

TestStand 4.2 and higher also has a report option (in the Report Options dialog) for specifying a report file path by expression.



0 Kudos
Message 4 of 7

Hi I am using Teststand 4.1.1. 


I am trying to make my Report Directory dynamic by specifying them in a 'dated folder' like, D:\ProjectA\05-24-2010, where I have a vi written to create the dated directory. So i need to get this vi run before the callback ReportOptions.


Q1) Can I put add a step to run this vi in the ReportOptions sequence? An output will be the date (eg 05-24-2010), which I save in FileGlobals.Dated


Q2) Then in the Parameters of ReportOptions, I set ReportOptions.Directory as ""D:\\ProjectA\\" + FileGlobals.Dated" something like that?


Can anyone please guide me on this? Thanks in advance.

0 Kudos
Message 5 of 7

Yes you can run a VI in the ReportOptions Sequence, add it to the Setup of that sequence. If you dont use FileGlobals.Dated anywhere else then use a Local instead. Just remeber FileGlobals are only global to sequences that are contained in a SequenceFile. They are not global across SequenceFile unless you are using the Batch Process Model.



You will probably have to set a number of other parameters up to work with ReportOptions.Directory. The best way to handle this is to setup up you exact conditions statically (ie via the Config | Report Options... menu ). Place a breakpoint in the ReportOptions (use a label if you dont have any steps in the ReportOptions sequence at the moment) and run your Sequence. Remeber to use Test UUTs or Single Pass. You dont have to use your full test sequence just create a simple one step sequence.


When you reach the break point, then you can browse the Parameters.ReportOptions and see what properties are required to ensure your reports are setup correctly.


Hope this helps.



Ray Farmer 



Ray Farmer
0 Kudos
Message 6 of 7

I'm trying to do the same thing but not having much success.

I enabled/added the "Report Options" callback and added expression to change the "ReportFilePath"

My main problem is that I want the user to select first the "test system" and "uut type" from a popup.

These results will be used to

1. dictate the destination folder for the report

2. determine the file name of the report

It seems that because the "Report Options" callback is run at the very beginning of the sequence, before the user has provided any input, my variables are not set yet to the correct values (hence my report is just having the "default" file name).

0 Kudos
Message 7 of 7