Loading ...
Sorry, an error occurred while loading the content.
 

marker and retrieve-marker question

Expand Messages
  • hilz <hsalameh@yahoo.com>
    Hi all: I am having a problem in using the marker and retrieve-marker to calculate page subtotals. here is what i am doing. in a table cell, i create a marker
    Message 1 of 1 , Feb 27, 2003
      Hi all:
      I am having a problem in using the marker and retrieve-marker to
      calculate page subtotals.

      here is what i am doing.
      in a table cell, i create a marker with the cumulative sum of a node
      set as follows:


      <fo:marker marker-class-name="previous_cumulative_total_marker">
      <xsl:value-of select="sum((preceding-
      sibling::Quantity)/NetValue)"/>
      </fo:marker>

      <fo:marker marker-class-name="this_cumulative_total_marker">
      <xsl:value-of select="sum((.|preceding-
      sibling::Quantity)/NetValue)"/>
      </fo:marker>



      then, in the static block, i retrieve the
      previous_cumulative_total_marker using the "first-statring-within-
      page"
      and this_cumulative_total_marker using the "last-ending-within-page",
      and i put them in two variables as follows :


      <xsl:variable name="previous_cumulative_total">
      <fo:retrieve-marker retrieve-class-
      name="previous_cumulative_total_marker" retrieve-boundary="page"
      retrieve-position="first-starting-within-page"/>
      </xsl:variable>

      <xsl:variable name="this_cumulative_total">
      <fo:retrieve-marker retrieve-class-
      name="this_cumulative_total_marker" retrieve-boundary="page" retrieve-
      position="last-ending-within-page"/>
      </xsl:variable>


      then, in the same static block, i want to show the result of the
      subtraction of those two variables from each other, so i do the
      following:
      <xsl:value-of select="$this_cumulative_total -
      $previous_cumulative_total"/>

      but this does not show anything.
      does anyone know why this does not work?

      Now, if i do
      <xsl:copy-of select"$previous_cumulative_total"/> , it shows me the
      number. same as for <xsl:copy-of select"$this_cumulative_total"/>
      but i cannot subtract those from each other? can i?

      why does it work with copy-of but not with value-of?

      and how can i get the result of the subtraction of the two variables?
      is there another way of doing this?

      any help is greatly appreciated.

      hilz
    Your message has been successfully submitted and would be delivered to recipients shortly.