From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

prefixing the report in the report file

Hi all,
I have a situation where i have to append the result in front(prefixing the uut report) after every UUT test.'Write UUT report' step writes at the end of the file.is there any way to append it in the beginning of the file.ie, I want ot have the latest uut report appended in the beginning of the file.
I am using 1.sequential model.2.DLL option.3..txt format  report file.teststand version 3.1
 
Thanks in advance,
Radha R
0 Kudos
Message 1 of 3
(2,652 Views)
Hi Radhu,

There is no easy way to just tell TestStand to do this in this order, this is because TestStand writes to the file after every UUT. The only way you would be able to do this is by removing all the writing of the report from the Test UUTs in the process model and storing all of the information in an array that would contain all of the report information. Then, at the end of Test UUTs you would iterate backwards through this array writing one at a time.

Three problems arise from this:

1) If you are doing this for extended amounts of time, you will be using a lot of memory as it will be making copies of the report information for each UUT.
2) You will need to make sure you are storing all relevant information for the report in order to create the report yourself at the end of the Test UUT.
3) You will no longer be using the TestStand API functions to write the report, because of this you will need to make sure you do all of the steps needed.

If you are unable to do this in this manner do to memory constraints and other problems, there is another solution outside of TestStand.

You would have to write each UUT to a different file, then after the UUTs are complete, you would write a program that writes the actually report. To do this, you would open each file (backwards to get your desired order) and write to a new file. As long as you left the new file open, it would append the other files to it. Unfortunately, you still have to read the old file to input into the new.

Both of these ways constitute an extreme amount of programming to get working, but both theoretically should work.

Brandon Vasquez | Software Engineer | Integration Services | National Instruments
0 Kudos
Message 2 of 3
(2,638 Views)

Thanks.

I was suspecting that, it would be difficult. Anyhow thanks that you made the reply.

Thanks,

Radha R

0 Kudos
Message 3 of 3
(2,626 Views)