S
Shaul Dar
I am using InfoPath 2003 to create a read-only view (really a report,
not a form). I then extract the view (.xsl) file from the .xsn file and
use it outside InfoPath to create an HTML display from an XML data
file. The latter part is done with .NET's parser. My problem is that
some formatting functionality available is InfoPath, specifically the
formatString function, is not available outside it. See e.g. XSL
snippet on bottom.
This functionality ("xdFormatting")is apparently defined in the name
space
xmlns:xdFormatting="http://schemas.microsoft.com/office/infopath/2003/xslt/formatting".
My question is if there is some InfoPath extenstions library then I
need to get and use to have access to this functionality? Other
suggestions? Does this problem go away in InfoPath 2007? (since they
have "browser-compatible" templates that can be displayed in IE w/o
InfoPath client)?
Thanks!
-- Shaul
-----------------------------
This XSL snippet uses "xdFormatting:formatString", if available, to
present a date/time value in some format. If the function is not
available it presents the date/time as is (as in the XML):
<xsl:choose>
<xsl:when test="function-available('xdFormatting:formatString')">
<xsl:value-of
select="xdFormatting:formatString("1961-09-18T03:00:00","datetime","locale:1033;dateFormat:dddd,
MMMM dd, yyyy;timeFormat:hh:mm:ss tt;""/>
</xsl:when>
<xsltherwise>
<xsl:value-of select=""1961-09-18T03:00:00""/>
</xsltherwise>
/xsl:choose>
not a form). I then extract the view (.xsl) file from the .xsn file and
use it outside InfoPath to create an HTML display from an XML data
file. The latter part is done with .NET's parser. My problem is that
some formatting functionality available is InfoPath, specifically the
formatString function, is not available outside it. See e.g. XSL
snippet on bottom.
This functionality ("xdFormatting")is apparently defined in the name
space
xmlns:xdFormatting="http://schemas.microsoft.com/office/infopath/2003/xslt/formatting".
My question is if there is some InfoPath extenstions library then I
need to get and use to have access to this functionality? Other
suggestions? Does this problem go away in InfoPath 2007? (since they
have "browser-compatible" templates that can be displayed in IE w/o
InfoPath client)?
Thanks!
-- Shaul
-----------------------------
This XSL snippet uses "xdFormatting:formatString", if available, to
present a date/time value in some format. If the function is not
available it presents the date/time as is (as in the XML):
<xsl:choose>
<xsl:when test="function-available('xdFormatting:formatString')">
<xsl:value-of
select="xdFormatting:formatString("1961-09-18T03:00:00","datetime","locale:1033;dateFormat:dddd,
MMMM dd, yyyy;timeFormat:hh:mm:ss tt;""/>
</xsl:when>
<xsltherwise>
<xsl:value-of select=""1961-09-18T03:00:00""/>
</xsltherwise>
/xsl:choose>