Hi folks, I got no reply to this email, hopefully you can fill me in on some details.
Will setNewLine() work without the following method call to the serializer? setFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true); TIA! ============================== Oliver White Software Engineer Product Development Westinghouse Signals Australia ============================== [EMAIL PROTECTED] vensys.com To: [EMAIL PROTECTED] cc: 08/06/03 02:49 Fax to: PM Subject: Problem with 'setNewLine()' (Xerces 2.1.0/WinNT4.0) Please respond to xerces-c-dev We are trying to force Xerces to serialize out XML with PC-style linebreaks (0x0D0A) and having no luck. Whatever we do UNIX-style ones are written out (0x0A). This is what we are doing: { XercesDOMParser parser; // the file we are parsing has been created by an XML-editing tool. That // tool has added some PC-style linebreaks at various spots parser.parse(path.c_str()); // append some new nodes, change some existing ones DOMImplementation* pImpl = DOMImplementationRegistry::getDOMImplementation(L"LS"); DOMWriter* pSerializer = ((DOMImplementationLS*)pImpl) ->createDOMWriter(); // *** what's wrong with this??? *** XMLCh crlf[3] = { 0x0D, 0x0A, 0x00 }; pSerializer->setNewLine(crlf); /////////////////////////////////////////////////// LocalFileFormatTarget out(path.c_str()) pSerializer->writeNode(&out, *parser.getDocument()); // cleanup } What comes out is a file with each existing 0x0D0A converted into an 0x0A! How can we stop this happening? ============================== Oliver White Software Engineer Product Development Westinghouse Signals Australia ============================== --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]