Changing the Display Format of Execution Time in an XML Report

TestStand 2017 Help

Edition Date: November 2017

Part Number: 370052W-01

»View Product Info

Download Help (Windows Only)
NI TestStand 2014 Help
NI TestStand 2014 SP1 Help
TestStand 2016 Help
TestStand 2016 SP1 Help
TestStand 2017 Help

XSL and JavaScript code generate the HTML code for the execution time information, for which the default display is in seconds. Complete the following steps to display the execution time information in Hour:Minutes:Seconds format.

  1. Open the .xsl file you want to change.
  2. Search for the CHANGE_TOTAL_TIME_FORMAT comment.
  3. Modify the TotalTime XSL template to use a different display format for execution time.
    1. Remove the comment tags from around the following XSL template and add comment tags around the existing TotalTime template in the horizontal.xsl file and in the report.xsl file:

      <xsl:template match="Prop[@Name='TotalTime']">

      <xsl:param name="reportOptions"/>

      <xsl:value-of disable-output-escaping="yes" select="user:GetTotalTimeInHHMMSSFormat (Value)"/>

      </xsl:template>

    2. Remove comment tags from around the following XSL template and add comment tags around the existing TotalTime template in the expand.xsl file:

      <xsl:template match="Prop[@Name='TotalTime']">

      <xsl:param name="includeStepResults"/>

      <xsl:param name="includeTimes"/>

      <xsl:param name="useLocalizedDecimalPoint"/>

      <xsl:value-of disable-output-escaping="yes" select="user:GetTotalTimeInHHMMSSFormat (Value)"/>

      </xsl:template>

horizontal.xsl

The following figure shows the modified execution time in a report using horizontal.xsl:

Modified Execution Time in Report Using horizontal.xsl

report.xsl

The following figure shows the modified execution time in a report using report.xsl:

Modified Execution Time in Report Using report.xsl

expand.xsl

The following figure shows the modified execution time in a report using expand.xsl:

Modified Execution Time in Report Using expand.xsl

WAS THIS ARTICLE HELPFUL?

Not Helpful