Link to home
Start Free TrialLog in
Avatar of dcx45
dcx45

asked on

Add XSL element at runtime?

Hi,
I'm using XSLT to do a runtime transformation of underlying XML file. I selectively need to add sort tag to the XSL.

I've confirmed that I'm inserting in the right place however

xsl.createElement("xsl:sort");

does not seem to create the right kind of element (and the sort doesn't work). When I do a debug output the local-name() for all other elements does not have the xsl: prefix, but the sort one does - I believe this has something to do with namespaces etc. but is beyond my current knowledge. Googling isn't helping much.

Any pointers?

Thanks!
SOLUTION
Avatar of Gertone (Geert Bormans)
Gertone (Geert Bormans)
Flag of Belgium image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
yes, that would be the way to add the namespace,
read my bit above, I don't recommend that you do it that way, still