list4xt : Mailing list for the XT users community.
[list4xt] illegal arguments error?
Subject: [list4xt] illegal arguments error?
User: Website From: Graham Stephenson (stepgram@nortelnetworks.com)
Date: 28/05/2001 - 17:33
Hello all,
I'm trying to use a GregorianCalendar object in my stylesheet but I keep
getting the error message 'set:illegal arguments' when I try to run it
through xt. (Saxon doesn't complain but returns incorrect results, that is,
it returns 1 for each of the three date fields.) Am I not passing arguments
to the method set(int, int, int) correctly?
Any help would be monsterously appreciated!
Here's a snippit of what I have:
start of my stylesheet ...
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:date="http://www.jclark.com/xt/java/java.util.GregorianCalendar"
version="1.0">
then later ....
<xsl:template match="ACTUAL-VALUE">
....
<!-- instantiate my Gregorian Calendar -->
<xsl:variable name="mygc" select="date:new()"/>
<!-- set the calendar parameters. Just passing in literals for now, will
write a function later. -->
<xsl:value-of select="date:set($mygc,2000,0,30)"/>
<!-- get values back out -->
<xsl:element name="afteryear"><xsl:value-of select="date:get($mygc,
Calendar.YEAR)"/></xsl:element>
<xsl:element name="aftermonth"><xsl:value-of select="date:get($mygc,
Calendar.MONTH)"/></xsl:element>
<xsl:element name="afterday"><xsl:value-of select="date:get($mygc,
Calendar.DAY_OF_MONTH)"/></xsl:element>
....
Thanks,
Graham
--
Mailing list for the XT users community. (http://lesboisfcu.org)
(mailto:list4xt-request@4xt.org?Subject=unsubscribe to unsubscribe)
Archive générée par hypermail 2b28 le 06/11/2001 - 11:46 CET
webmaster@4xt.org
|