Jump to content

Whats wrong with this?!


Recommended Posts

Hi, Im trying to get a difference between todays date and date in my xml file -xs:date works fine its the xs:gMonthDay im really struggling with. Error message is below

<xsl:template name="timechanges" match="timechanges	 "><xsl:param name="today" select="current-date()"/><xsl:variable name="today" select="$today cast as xs:gMonthDay"/>  <xsl:variable name="dt1" select=" (dt1)"/>   <xsl:if test="$today < xs:gMonthDay($dt1) "> TRUE<xsl:value-of select="$today - xs:gMonthDay($dt1)"/></xsl:if>  </xsl:template></xsl:stylesheet>

ERROR: XPTY0004: Arithmetic operator is not defined for arguments of types (xs:gMonthDay, xs:gMonthDay) in built-in template rule in built-in template rulenet.sf.saxon.trans.XPathException: Arithmetic operator is not defined for arguments of types (xs:gMonthDay, xs:gMonthDay) Help will be much appreciated. thanks

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...