NI TestStand

cancel
Showing results for 
Search instead for 
Did you mean: 

How to modify the teststand report font size?

Hello,

I am wondering if it is at all possible to make modifications to the UUT Report.
I would like to have my report on one page but the HTML header, (serial number, date, pc ...)font size takes up half the 1st page, anyone know how?

Also, I would like to automatically print out the report when the sequence passes, anyone know how?

Thanks in advance
D.S
0 Kudos
Message 1 of 9
(4,935 Views)
I don't know if there is an easier way, but we have modified the ReportGen_html.seq file for other purposes (specifically to allow entering a single line report entry Label, to allow breaking up the long reports such as marking the beginning of each For Loop, etc. using a custom step).

One of the things that we also played with was the Font Size.

Copy the your existing Reportgen_html from the C:\Program Files\National Instruments\TestStand 3.1\Components\NI\Models\TestStandModels directory and put it in the ...User\Models\TestStandModels directory.
Modify only this file. Your Paths order should find the one in the User directory before the NI directory and use that file.

Find the "PutOneResultInReport" subsequence in the reportgen_html.seq file. Do a search for "Font" and I think that it will become somewhat apparent to you how to modify the HTML code that is entered for the report.

Mike
0 Kudos
Message 2 of 9
(4,914 Views)
Hi demo,

In the reportgen_html.seq file you will find a sequence called 'AddReportHeader'.

You will need to change the html tags associated with the items you wish to change. eg the title the font size is set by the tag "H1 and /H1".

Hope this help
Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 3 of 9
(4,914 Views)
Hi,

Adding to my last.

In the Sequence 'AddReportHeader' you will find a step called 'Set Report Header'. This step sets the header size to H1 for the Report Title, then sets the size to H3 for the remaining text eg Station ID, UUT Serial Number etc.

In the same sequence, the Step 'End List' terminates the header size H3.

Likewise in sequence 'AddReportFooter' this has a step that sets the footer header size to H2.


The Sequence Name and File Path, this is done in the sequence AddSequenceResultToReport, the steps are 'Add Sequence Name' and 'Add Sequence File Path'. The size used is H4.

The Sequence End Marker is done in the sequence AddSequenceResultToResult and the step is 'Add Sequence End Marker'

(I was going to put the tags to look for in this text but its such a hassle...)

Hope this information helps.
Regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 4 of 9
(4,900 Views)
Hey D.S.

This example program should help with printing your report:

Print HTML Report Automatically after Each UUT

I hope this helps!

Regards,

Sarah Miracle
National Instruments
0 Kudos
Message 5 of 9
(4,890 Views)
I searched and found all FONT SIZE=-1 instances and changed them all to -5 but there is no difference in the report. So, the question remains. How do you change the font size globally for the HTML report?

Thanks,

Daniel L. Press
PrimeTest Corp.
www.primetest.com
0 Kudos
Message 6 of 9
(4,866 Views)
Hi

One way is to modify the header is to add "<font size = -2>" before every data element. For example in the statement step "Add UUT Result" in sequence "AddReportHeader" should be changed as shown below.

Locals.Header += "<TR><TD NOWRAP='NOWRAP'><B><LI>" + ResStr("MODEL", "RPT_HEADER_UUT_RESULT") + "</B><TD><B><FONT COLOR=" + Locals.StatusColor + ">" + ResStr("STEP RESULT STATUS", Locals.Status, Locals.Status) + "</FONT></B>" + Locals.ErrorText + "\n"

Should be changed to
Locals.Header += "<TR><TD NOWRAP='NOWRAP'><B><LI><font size = -2>" + ResStr("MODEL", "RPT_HEADER_UUT_RESULT") + "</font></B><TD><B><FONT size = -2 COLOR=" + Locals.StatusColor + ">" + ResStr("STEP RESULT STATUS", Locals.Status, Locals.Status) + "</FONT></B>" + Locals.ErrorText + "\n"

You will need to add font information to every line to get the smaller size.

I hope this helps.
Regards
Anand Jain
National Instruments
0 Kudos
Message 7 of 9
(4,857 Views)
Hi demo,

Alternative set the base font to a smaller number.

I believe the basefont tag is not used in the reportgen_html.seq therefore the default font size will be 3.

You could add the line <basefont size = 2> after the body tag and add </font> before the end body tag.

regards
Ray Farmer
Regards
Ray Farmer
0 Kudos
Message 8 of 9
(4,844 Views)
Hi,

I have attached a small example, use something like notepad to view the source text and your web browser to view the actual affect.

You will notice that just setting the base font will not fix everything.
You will have to edit all the header tag in the reportgen_html.seq because these are not affected by setting the base font.

Regards
Ray Farmer


(Even though its only a small file I had to zip it up to get rid of this error : -
"The file does not have a valid extension for an attachment. jpg,gif,txt,xls,vi,zip,doc,bmp,llb,pdf,png are the valid extensions")
Regards
Ray Farmer
0 Kudos
Message 9 of 9
(4,839 Views)