0
I have the following code snippet
string xmlText = Encoding.UTF8.GetString(relFinalProj.XmlAnexo.MidAnexo);
where the "relFinalProj.XmlAnexo.Midattachment" is an array of bytes. When encoding all accented letters are replaced by special characters like "?". How to go back to the accented letters again?
Example of text after encoding:
you have to know which encoding used in the text... then you use the correct to convert...
Encoding.ASCII.GetString(...)
orEncoding.Default.GetString(...)
– Rovann Linhalis
Is this XML generated by you? Wouldn’t it also be the case to escape this content with the
<![CDATA[]]>
? Thus already preventing in relation to other special characters that the text can contain and prevent xml breaking?– Leandro Angelo