Re: [xsl] sum up float values problem

Subject: Re: [xsl] sum up float values problem
From: "Markus Gamperl" <markus.gamperl@xxxxxx>
Date: Sun, 30 Apr 2006 18:24:03 +0200 (MEST)
Hello!

Thanks a lot for your help - I have it running now! ;-)

But please allow me one more question. Is there a way to get the sum result
into a variable or parameter? I would need the sum for further more
calculations...

Thanks
Markus


> --- Urspr|ngliche Nachricht ---
> Von: "Dimitre Novatchev" <dnovatchev@xxxxxxxxx>
> An: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Betreff: Re: [xsl] sum up float values problem
> Datum: Fri, 28 Apr 2006 05:23:48 -0700
> 
> Florent explained it nicely.
> 
> TO summarise: When using a library of templates/functions (FXSL) one
> has to download this library and have a look at some examples how to
> use it.
> 
> One additional (and probably the most readable) article about FXSL is at:
> 
>   
>
http://www.mulberrytech.com/Extreme/Proceedings/xslfo-pdf/2003/Novatchev01/EML2003Novatchev01.pdf
> 
> 
> 
> 
> --
> Cheers,
> Dimitre Novatchev
> ---------------------------------------
> Truly great madness cannot be achieved without significant intelligence.
> 
> 
> 
> On 4/28/06, Markus Gamperl <markus.gamperl@xxxxxx> wrote:
> > I do not understand it:
> >
> > When I copy this code into my stylesheet the processor wants to import a
> > stylesheet "transform-and-sum.xsl" but where is this file???
> >
> > The explanation is very poor... Do you have more tips?
> >
> > <xsl:stylesheet version="1.0"
> > xmlns:xsl="http://www.w3.org/1999/XSL/Transform";;
> > xmlns:func-transform="f:func-transform"
> > exclude-result-prefixes="xsl func-transform"
> > >
> >   <xsl:import href="transform-and-sum.xsl"/>
> >
> >   <xsl:output method="text"/>
> >
> >   <func-transform:func-transform/>
> >
> >    <xsl:template match="/">
> >      <xsl:call-template name="transform-and-sum">
> >        <xsl:with-param name="pFuncTransform"
> >                        select="document('')/*/func-transform:*[1]"/>
> >        <xsl:with-param name="pList" select="/*/*"/>
> >      </xsl:call-template>
> >    </xsl:template>
> >
> >    <xsl:template match="func-transform:*">
> >      <xsl:param name="arg" select="0"/>
> >      <xsl:value-of select="translate($arg, ',', '')"/>
> >    </xsl:template>
> >
> > </xsl:stylesheet>
> >
> >
> > > --- Urspr|ngliche Nachricht ---
> > > Von: "Dimitre Novatchev" <dnovatchev@xxxxxxxxx>
> > > An: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> > > Betreff: Re: [xsl] sum up float values problem
> > > Datum: Thu, 27 Apr 2006 12:04:33 -0700
> > >
> > > > >     sum(/*/*/xs:double(translate(.,',','.')))
> > > >
> > > >  In XSLT 1.0?
> > >
> > > In XSLT 1.0 I'd use the transform-and-sum template/function of FXSL
> 1.x
> > >
> > > Search for "transform-and-sum" to get some examples of its usage.
> > >
> > >
> > >
> > > --
> > > Cheers,
> > > Dimitre Novatchev
> > > ---------------------------------------
> > > Truly great madness cannot be achieved without significant
> intelligence.
> > >
> > >
> > > On 4/27/06, Florent Georges <darkman_spam@xxxxxxxx> wrote:
> > > > Dimitre Novatchev wrote:
> > > >
> > > > > Exactly as explained by Dr. Kay:
> > > >
> > > > >     sum(/*/*/xs:double(translate(.,',','.')))
> > > >
> > > >  In XSLT 1.0?
> > > >
> > > >  Regards,
> > > >
> > > > --drkm
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > >
> >
>
___________________________________________________________________________
> > > > Faites de Yahoo! votre page d'accueil sur le web pour retrouver
> > > directement vos services prifiris : virifiez vos nouveaux mails,
> lancez
> > vos
> > > recherches et suivez l'actualiti en temps riel.
> > > > Rendez-vous sur http://fr.yahoo.com/set
> > >
> >
> > --
> > GMX Produkte empfehlen und ganz einfach Geld verdienen!
> > Satte Provisionen f|r GMX Partner: http://www.gmx.net/de/go/partner
> >
> >
> 
> 
> --
> Cheers,
> Dimitre Novatchev
> ---------------------------------------
> Truly great madness cannot be achieved without significant intelligence.
> 

-- 
GMX Produkte empfehlen und ganz einfach Geld verdienen!
Satte Provisionen f|r GMX Partner: http://www.gmx.net/de/go/partner

Current Thread