Place the total of the invoice on the last page of the invoice detail lines

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Ly Cao
    New Member
    • Oct 2008
    • 2

    #1

    Place the total of the invoice on the last page of the invoice detail lines

    Please shine the light, how do you place the total on the last page of the invoice? how do you find out the it is a last page of the detail lines then place the total of the invoice into that last page.
  • Dormilich
    Recognized Expert Expert
    • Aug 2008
    • 8694

    #2
    Originally posted by Ly Cao
    Please shine the light, how do you place the total on the last page of the invoice?
    usually by writing it on the sheet with the largest page number.

    (what I wanted to make clear is, if you don't provide us with information we can't answer properly, see how to ask a question )

    PS if you post code, don't forget to use [code] tags

    Comment

    • Ly Cao
      New Member
      • Oct 2008
      • 2

      #3
      Originally posted by Dormilich
      usually by writing it on the sheet with the largest page number.

      (what I wanted to make clear is, if you don't provide us with information we can't answer properly, see how to ask a question )

      PS if you post code, don't forget to use [code] tags
      Sorry, I realized it after it had been posted, I then tried to attach more info but some how it didn't save. Hope it works this time.
      I am using XSL version 1.1 in solaris 5.8 and xml version 1.0 encoding="UTF-8"
      Please find attached an XSL which display total on the page by itself. Please show me how to get it to display on the last page of the details line. <fo:static-content flow-name="xsl-region-after">
      <fo:block font-size="10pt" font-weight="bold" text-align="center">
      <fo:table border="0.2pt solid rgb( 13, 18, 137)">
      <fo:table-column column-width="30mm"/>
      <fo:table-column column-width="80mm"/>
      <fo:table-column column-width="25mm"/>
      <fo:table-column column-width="25mm"/>
      <fo:table-column column-width="20mm"/>
      <fo:table-body>

      <fo:table-row>
      <fo:table-cell number-rows-spanned="3" padding="1mm">
      <fo:block text-align="left" font-weight="normal" padding="0.8mm" >
      </fo:block>
      </fo:table-cell>

      </fo:table-row>

      <fo:table-row>
      <fo:table-cell padding="1mm" border="0.2pt solid rgb(13, 18, 137)">
      <fo:block text-align="right" font-weight="bold">
      SALE VALUE (EXCLUSIVE OF GST)
      </fo:block>
      <fo:block text-align="right" font-weight="bold" space-after="1mm">
      GST AMOUNT
      </fo:block>
      </fo:table-cell>
      <fo:table-cell border="0.2pt solid rgb(13, 18, 137)" padding="1mm">
      <fo:block text-align="right" font-weight="normal" >
      $<xsl:value-of select="format-number(substrin g-after(row[1]/column[49
      ],'$') + substring-after(row[1]/column[43],'$') + substring-after(row[1]/column[
      44],'$') + substring-after(row[1]/column[45],'$') - substring-after(row[1]/colum
      n[78],'$') - (substring-after(row[1]/column[66],'$') * row[1]/column[42]),'0.00
      ')"/> </fo:block>

      <!-- GST AMOUNT -->
      <fo:block text-align="right" font-weight="normal" >
      <xsl:value-of select="row[1]/column[70]"/>
      </fo:block>
      </fo:table-cell>
      </fo:table-row>

      <fo:table-row>
      <fo:table-cell padding="1mm" border="0.2pt solid rgb(13, 18, 137)">
      <fo:block text-align="right" font-size="11pt" font-weight="bold" space
      -before="2mm">
      TOTAL AMOUNT PAYABLE
      </fo:block>
      </fo:table-cell>
      <fo:table-cell padding="1mm" border="0.2pt solid rgb(13, 18, 137)">
      <fo:block text-align="right" font-size="11pt" font-weight="bold" space
      -before="2mm">
      $<xsl:value-of select="format-number((substri ng-after(row[1]/column[4
      9],'$') + substring-after(row[1]/column[43],'$') + substring-after(row[1]/column
      [44],'$') + substring-after(row[1]/column[45],'$') - substring-after(row[1]/colu
      mn[78],'$') - (substring-after(row[1]/column[66],'$') * row[1]/column[42])) + s
      ubstring-after(row[1]/column[70],'$'),'0.00')"/>
      </fo:block>
      </fo:table-cell>
      </fo:table-row>
      </fo:table-body>
      </fo:table>
      </fo:block>
      <fo:block id="last-page"/>
      </fo:static-content>

      Comment

      • Dormilich
        Recognized Expert Expert
        • Aug 2008
        • 8694

        #4
        with xsl-fo you can create a "last page" template where you put your total in. <fo:static-content> seems not to be the most suited place for the total. (as I can tell from a quick read at www.w3schools.c om/xslfo/)

        regards

        Comment

        Working...