I have created an apex class which created an xml using:
xmlW.writeStartDocument('windows-1255','1.0');
but I get the following error:
Underlying stream encoding 'UTF-8' and input parameter for writeStartDocument() method 'windows-1255' do not match.
How can I create an XML with another encoding than UTF-8?