RE: date:format-date causing "No flow in page-sequence"

"Brown, James" <[email protected]>
Newsgroups gmane.text.xml.xslt.extensions
Message-ID <6E6C9319C3F683419F5E804751FA38DF078643@cator-exch1.na.uis.unisys.com>
Further info.

I have stepped back to a very simple example.  Appears that 
  <xsl:variable name="xyz" select="date:format-date($now, 'yyyy MM dd hh:mm:ss')"/>
is not working yet the 
  <xsl:call-template name="date:format-date">
syntax is.

Any ideas?  The working directory contains the necessary date and str template XSL files (date.format-date.function.xsl and str.padding.template.xsl respectively).

---- test.xml ----
<?xml version="1.0" encoding="UTF-8"?>
<dates>
  <date>2003-10-25</date>
</dates>

---- test.xsl ----
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:date="http://exslt.org/dates-and-times" extension-element-prefixes="date">
    <xsl:import href="date/functions/format-date/date.format-date.template.xsl" />
    <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes" />
    
    <xsl:template match="dates">
      <xsl:variable name="now" select="date:date-time()"/>
      NOW : <xsl:value-of select="date"/>
      
      <xsl:variable name="result">
        <xsl:call-template name="date:format-date">
          <xsl:with-param name="date-time" select="date"/>
          <xsl:with-param name="pattern" select="'MMM dd,yyyy'"/>
        </xsl:call-template>
      </xsl:variable>
      RESULT: <xsl:value-of select="$result"/>

      <xsl:variable name="result">
        <xsl:call-template name="date:format-date">
          <xsl:with-param name="date-time" select="$now"/>
          <xsl:with-param name="pattern" select="'yyyy MM dd hh:mm:ss'"/>
        </xsl:call-template>
      </xsl:variable>
      NOW: <xsl:value-of select="$result"/>
      <!-- This one does not work! -->
      NOW (Formatted): <xsl:variable name="xyz" select="date:format-date($now, 'yyyy MM dd hh:mm:ss')"/>
      NOW: <xsl:value-of select="$xyz"/>
      <!---->
    </xsl:template>
</xsl:stylesheet>

                                  Cheers,
                                  James

THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. 


> -----Original Message-----
> From: Brown, James 
> Sent: 2004 January 05 08.20
> To: [email protected]
> Subject: [exslt] date:format-date causing "No flow in page-sequence"
> 
> 
> When trying to use  the following in an XSL-FO template I 
> receive an "org.apache.fop.apps.FOPException: No flow in 
> page-sequence" exception:
>   <xsl:value-of 
> select="date:format-date('2003-01-02T12:34:15', 'CCYY MM DD 
> hh:mm:ss')"/>
> 
> If I remove the line, or even just replace with
>   <xsl:value-of select="date:date-time()"/>
> all is fine.  Any ideas?
> 
> 
>                                   Cheers,
>                                   James
> 
> THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE 
> PROPRIETARY MATERIAL and is thus for use only by the intended 
> recipient. If you received this in error, please contact the 
> sender and delete the e-mail and its attachments from all computers. 
> 
> _______________________________________________
> exslt mailing list
> [email protected]
> http://www.exslt.org/list
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.