imisresiamn
New Member
I am consuming messages and the messages are stored in byte() format and I tried to convert it with proper encoding to a string but still see the unicode characters when writing it to a file. What am I doing wrong here\[code\] xwriter = New XmlTextWriter(filename,Encoding.UTF8) Dim body As String = System.Text.Encoding.UTF8.GetChars(result.Body)'body = replaceIllegalXMLChars(body) ///tried converting them explicitly but did not work xwriter.WriteString(post) xwriter.Flush()\[/code\]Sample output:\[code\] <avataruri>http://a0.twimg.com/profile_images/1651487744/Vman_normal.jpg </avataruri> <suitable>0</suitable>\[/code\]