NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

Additional Results - ASCII Report Format

Hello All,

 

When using "Additional Results", and having an ASCII Report Format, how do you increase the "Name" beyond 26 characters?

 

Its like there are 2 invisible columns, to accomodate for "Name" and "Value to log", but you can only use a 26 character Name, before you enter the second column.

 

Any ideas?

0 Kudos
Message 1 of 3
(3,838 Views)

Hey kalachnik,

 

This can be done, but it might take a bit of modification.

 

The first thing I did was add the ReportOptions callback to my sequence file. In that callback, I added a Statement step with the following expression: Parameters.ReportOptions.LabelSize = 60    . This allows names up to 60 characters long in the results. 

 

However, the downside to this is that the Value to Log of the additional results will no longer line up with the result of normal steps, such as an Action step. Since this makes the report difficult to understand, we should probably increase the space between the name and value columns for all report results. That will require modifying the report generation sequence.

 

1) Go to Configure > Result Processing, click the Options button for the report, and on the Contents tab, set the report generator to Sequence instead of DLL. This allows us to make changes in a TestStand sequence file to affect the report generation.

 

2) Navigate to <TestStand>\Components\Models\TestStand Models and open reportgen_txt.seq. This is the sequence file which controls ASCII report generation. Find the sequence called PutOneResultInReport_lmpl. This sequence puts a single result line into the report.

 

3) One of the steps is "Get Gap String", and it has a statement of the following form: Locals.GapBetweenNameAndResult = Locals.StepNameLength >= 30 ? " " : Left("                               ", 30 - Locals.StepNameLength). This statement indents the result by 31 spaces if the step name is longer than 30 characters, or by 30-(length of step name) if the name is shorter than 30 characters. We need to change those thresholds.

 

4) Set the expression to the following: Locals.GapBetweenNameAndResult = Locals.StepNameLength >= 60 ? " " : Left("                                                             ", 60 - Locals.StepNameLength).  I changed both instances of "30" to "60", and changed the blank string from 31 spaces to 61. This will cause the results to be indented further, which makes the Name column wider on the report.

 

 

This should do it, and of course you can tweak the actual values for your specific needs. You might also consider using one of the other report formats, such as XML or ATML. These formats are a bit more dynamic and can more easily handle longer names. I hope it helps, and let us know if you have any more questions about it!

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

Thanks ever so much for your concise reply.

 

I ended up just dumping the extra information into the "Value to log" column, but I feel as you have gone to the effort to reply, I shall change it.

 

Unfortunately we cannot use the other Report Formats, because the database system we use is very fussy. 

 

Smiley Happy

 

 

0 Kudos
Message 3 of 3
(3,802 Views)