Article View: fr.comp.text.xml
Article #9207Re: Need help... Test an element??
From: Lupo
Date: Thu, 10 May 2001 15:28
Date: Thu, 10 May 2001 15:28
20 lines
1885 bytes
1885 bytes
John wrote: > > > Hi, I'd like to write comments about my data. > > for exemple if RecrutNum >0 .. I'd like to write "increase" > > RecrutNum =0 .. I'd like to write "no change" > > else I'd like to write "decrease" > > > The general principle of what you have done is OK but you don't need the @ > sign in your test. <xsl:when test="@RecrutDiscard > 0"> should be <xsl:when > test="RecrutDiscard > 0"> since recrutDiscard is an element not an > attribute. You still need to define the selected text as a number in order to perform the comparison. The node's value is, by default, a string. Therefore, you need <xsl:when test="number(RecrutDiscard) > 0">. -Lupo
Technical Details
Message-ID:
<3AFAB397.782CD6FF@yahoo.com>Path:
arc1-ca.pugleaf.net!newsfeed.google.com!newsfeed.stanford.edu!newsfeed.gamma.ru!Gamma.RU!news1.spb.su!news1.relcom.ru!racoon.riga.lv!secnews.netscape.com!not-for-mailReferences:
<B1uK6.72$aB5.22415@tengri.easynet.fr> <OYWRfNW2AHA.404@tkmsftngp07>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1006ac,92ec00df5e179645 X-Google-Attributes: gid1006ac,public X-Google-Thread: 1047a4,92ec00df5e179645 X-Google-Attributes: gid1047a4,public X-Google-Thread: 110868,92ec00df5e179645 X-Google-Attributes: gid110868,public X-Google-Thread: 114f60,92ec00df5e179645 X-Google-Attributes: gid114f60,public X-Google-ArrivalTime: 2001-05-10 08:31:39 PST Path: arc1-ca.pugleaf.net!newsfeed.google.com!newsfeed.stanford.edu!newsfeed.gamma.ru!Gamma.RU!news1.spb.su!news1.relcom.ru!racoon.riga.lv!secnews.netscape.com!not-for-mail From: Lupo <tcantalupo@yahoo.com> Newsgroups: fr.comp.text.xml,microsoft.public.xml,microsoft.public.xsl,netscape.public.dev.xml Subject: Re: Need help... Test an element?? Date: Thu, 10 May 2001 11:28:23 -0400 Organization: http://todd.cantalupo.org Lines: 20 Message-ID: <3AFAB397.782CD6FF@yahoo.com> References: <B1uK6.72$aB5.22415@tengri.easynet.fr> <OYWRfNW2AHA.404@tkmsftngp07> NNTP-Posting-Host: 93hdcp145.chordiant.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailer: Mozilla 4.77 [en] (WinNT; U) X-Accept-Language: en To: John <jardiss@tesco.net>