In Xalan-J, the solution would be to output to a SAX stream as UTF-8 or UTF-16, and then route that stream through a separate serializer which converts it to the appropriate encoding. It's been too long since I've looked at Xalan-C, but I presume something similar is possible there.
______________________________________ "... Three things see no end: A loop with exit code done wrong, A semaphore untested, And the change that comes along. ..." -- "Threes" Rev 1.1 - Duane Elms / Leslie Fish ( http://www.ovff.org/pegasus/songs/threes-rev-11.html)