Hi Thomas,
I believe the assert is a bug that has since been fixed. What version of
Xalan-C are you using?
You cannot "escape" stylesheet parameters using XML entities, if that's
what you're trying to do. If you're dealing with C++ escaping issues,
that's different. You may also be having problems because your parameters
are XPath string literals,
Can you provide a trivial stylesheet, input document, and parameter value
you want to set, so we can understand what you're trying to do? Otherwise,
I don't know what we can do to help.
Thanks!
Dave
"Thomas F.
O'Connell" To:
[email protected]
<[EMAIL PROTECTED] cc:
com> Subject: Escaping Stylesheet
Parameters
07/16/2003 11:03
AM
Please respond
to xalan-dev
I've got a process that is applying a stylesheet to an XML document, and
the process needs to set a parameter in the stylesheet. What I'm having
trouble with, currently, is that the parameter might have reserved
characters in it (I'm currently struggling with '). Now I want the
parameter to be something I can display in an unescaped format once the
transformation is done.
Currently, as soon as I pass the parameter, I'm getting this from Xalan:
PlatformSupport/DOMStringHelper.cpp:523: void substring(const
XalanDOMString&, XalanDOMString&, unsigned int, unsigned int): Assertion
`theStartIndex + theLength <= theStringLength' failed.
This seems to be happening as soon as the parameter is set (or the
attempt is made to set the parameter), as I've removed all references to
the parameter from the stylesheet just to see whether I could
successfully set it.
Is there any way to pass an unescaped parameter with reserved characters
to a stylesheet? Or is there a way of escaping it before setting it and
then unescaping it during the transformation process?
Thanks!
-tfo