Hello:
I am sorry I do not quite understand. Let me try to be explain what is
happening on my side. There is an external application that is
supplying this parameter called "longdate" to the style sheet and that
is a complete black box to me. All the information I have is that this
parameter called longdate is in long format. So on XSL:fo I just say
<xsl:param name="longdate"/>
The value I get when I try to print this is 1143228551205 (just as an example).
Is there any way to use javascripts on XSL:FO. I know it can be done
on XSLT. Can it be done on XSL:FO? Otherwise, can anyone please help
me get a solution to this?
Thanks in advance for all your help.
----------------------------------------------------------------------------------------------------------------
Post by xslt xslfoThe $in which is in milliseconds is an external parameter declared on
the stylesheet using
The actual type of $in depends on whether you have declared the type in the
xsl:param declaration (I suspect you haven't, or you would have told us) and
on the object supplied in the invocation of the stylesheet. If you are
running from the command line, then the value will be untypedAtomic. If you
are running from a Java application, then it depends on what you supply in
the call: if you supply a Long, the value will be an xs:integer; if you
supply a String, it will be an xs:string.
Michael Kay
http://www.saxonica.com/
Post by xslt xslfo--------------------------------------------------------------
-------------------------------------------------------
You've confirmed that version="1.0", and I suspect despite
what you say
that
$in is untypedAtomic rather than xs:long. In the calculation, try
wrapping
it as xs:integer($in).
Michael Kay
http://www.saxonica.com/
-----Original Message-----
Sent: 13 April 2006 17:52
Subject: RE: [xsl] Convert milliseconds into date
This is what I am using;
Post by xslt xslfoxmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:fo="http://www.w3.org/1999/XSL/Format"
xmlns:xdt="http://www.w3.org/2005/02/xpath-datatypes"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
The $in is date in "long" format which is passed as a
paramter to the
XSL:FO. For testing, I have hardcoded the value to 1143230642199.
Does this help?
--------------------------------------------------------------
------------------------
I think this is what you would get if
(a) the stylesheet specifies version="1.0"
and
(b) the value of $in is untypedAtomic.
Since you haven't shown us the xsl:stylesheet element or the
declaration of
$in, this is just a hypothesis.
Michael Kay
http://www.saxonica.com/
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
--~--
Delete Reply Forward Spam Move...
Previous | Next | Back to Messages
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
--~--
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
--~--
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
--~--
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail:
--~--
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-***@lists.mulberrytech.com>
--~--