[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

maker and retrieve-marker question

Subject: maker and retrieve-marker question
From: HS <hsalameh@xxxxxxxxx>
Date: Fri, 28 Feb 2003 17:27:09 -0800 (PST)
fo marker variable
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 two markers with the
cumulative sum of a nodeset 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


__________________________________________________
Do you Yahoo!?
Yahoo! Tax Center - forms, calculators, tips, more
http://taxes.yahoo.com/

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.