NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Two Reports

I want to generate two reports from one execution. One has to be default html and the other needs to be text (the text is basically for the reprots to be automatically picked up an analysis utility/tool.
I am fowlloing an approach where I doubled the steps in TestReport Sequence and have placed a Set Report Format(= txt) in between. The approach is no where close to working and to add to it I havent worked with TestStand earlier.
Now I wanted help with two things .

1. Can this be considered as an approach ?Or is there any other recommended way of doing it .

2. How do I access the Format property . I have been trying Report.Format /Parameter.reportOptions.Format ?
if I try to set parameter.reportoptions.format it gives me the following error
**Incorrect ActiveX Reference type in 'Parameters.ReportOptions.Format'.
A reference to an object of type 'Report' was expected.**


and in case of report.options

**Unknown variable or property name 'Report'.
Error accessing item 'Report'.**

Do I have to set this property in a different way .


Thanking in anticipation.

Sumit
0 Kudos
Message 1 of 16
(5,170 Views)
Hi Sumit,

You were actually on the right track with altering the steps in the process model that generate the report. However, the sequence where the report is actually saved (with the correct format) is in the Test UUT sequence of the process model. All you have to do is add a statement step after Write UUT report that sets the format to txt, clears the report and sets the file path using the expressions:
Locals.ReportOptions.Format="txt", Locals.Report="", Locals.ReportFilePath=Locals.ReportFilePath+".txt"

You can then repeat the previous five steps to create the report. I am including the example process model so you can see how this can be done. Change your Station Options to use this model instead of the default model and run as Test UUT.

Thanks,
Caroline
National Instruments
Thanks,
Caroline Tipton
Data Management Product Manager
National Instruments
Message 2 of 16
(5,137 Views)
Thanks Caroline.

I have not been able to open the attached seq file . I am using TestStand2.0 .Can you please save it under TS2.0 and attach it again.I am pretty sure this would work for me . Thanks again.

Sumit
0 Kudos
Message 3 of 16
(5,133 Views)
Caroline,

I tired what I get from you message I guess I still missed out on something . I guess looking at the attachement would be more helpful. I will really appreciate if you can save your attachement in TestStand2.0 and post it again . You can send snapshots if it can not be odne.

Thanking you in strong anticipation
Sumit
0 Kudos
Message 4 of 16
(5,128 Views)
Hi,

Dont forget, if you use Single Pass rather than Test UUT's as the entry point you will have to make the changes in Single Pass sequence as well.

Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 5 of 16
(5,122 Views)
Hi,

Here is the 2.0 version. I have tested this and it seems to work correctly. Again, this one has the changes made for the Test UUT. If you are using Single Pass you will have to make the same changes in that sequence file.

Thanks,
Caroline
National Instruments
Thanks,
Caroline Tipton
Data Management Product Manager
National Instruments
0 Kudos
Message 6 of 16
(5,111 Views)
Caroline,

Why does the text file that is stored has .html in its file name ?
I tried things like below. But it would still not get rid of the .html.txt .

Locals.ReportFilePath= Left(Locals.ReportFilePath,len(Locals.ReportFilePath)-5)+".txt",

I tried setting the extension as well but it would still have two extensions.

Please assist. Thanks

Sumit
0 Kudos
Message 7 of 16
(5,104 Views)
Hello Sumit,

All you need to do is add the expression:
SearchAndReplace(Locals.ReportFilePath, ".html", "")
after the other two postexpressions in the Statement step. This will take out the .html in the path name.
I am also attaching the modified process model.

Thanks,
Caroline
National Instruments
Thanks,
Caroline Tipton
Data Management Product Manager
National Instruments
0 Kudos
Message 8 of 16
(5,084 Views)
Repeating the same steps for Single step execution doesnt seem to work .
Please advise if something more needs to be done in case of single step execution.

Thanks
Sumit
0 Kudos
Message 9 of 16
(5,078 Views)
Hi,

Do you mean Single Pass?

Single step execution seems to suggest running in Interactive Mode.
If this is the case, to get a report you need to use the Menu Item 'Run Selected Step(s) Using ....' and select the entry point Test Uut's or Single Pass.

Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 10 of 16
(5,062 Views)