Get text from windows form

Mar 21, 2013 at 4:27 PM
Hello,

i have write an application wich include a browser.
In yhis browsew run a poker application.

Witch rhis code:
Dim bytesCount As Integer = recv(socketHandle, buf, count, socketFlags)
    If bytesCount > 0 Then
        Dim newBuffer As Byte() = New Byte(bytesCount - 1) {}
        Marshal.Copy(buf, newBuffer, 0, bytesCount)
        Dim s As String = System.Text.UnicodeEncoding.ASCII.GetString(newBuffer)
        Dim tw As TextWriter = New StreamWriter("log.txt")
        tw.Write(s)
        tw.Close()
        File.AppendAllText("hook.txt", vbNewLine + vbNewLine + s)
i obtain this text:
<?xmlversion="1.0"encoding="utf-16"?><CMessagexmlns:xsd="http://www.w3.org/2001/XMLSchema"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><type>status</type><from>server</from><to>1.1::::hljhx2ekkczr5k0tkio3wa00::::1ec0c69::::6b83</to><vars>r=1&r4=1_1_1_0_1&e7=35&v=618515&z7=0_0&u1=1&k=1&b8=1&o7=1&x=1;1;2;5;1;1;;;;&spos3_0=po_1#co_4#C1&c1=;;1;2;;;;;;&p7=1&z8=1&d2=0&k1=;;;C1|B1;;;;;;&j3=1_1_1_0_0&z1=2&a9=4&w1=1&a=6#[mappa78]:Fold#0#0#0#0#0;6#[lampolight]+%3a+Ha+vinto+un+piatto+di+0%2c10#0#0#0#0#0&h1=;;1;1;;;;;;&a8=1&t1=1&c=0&c2=0&l1=;;;;;;;;;&w=1;1;1;1;1;&b2=15&s1=2;2;1;1;2;2&b1=;;225765;226095;;;;;;&r1=10&a1=;;1;1;;;;;;&e8=1;1;2;2;1;1;;;;&d=-1&m3=1;1;1;1;1;1&x1=1&p1=;;3;;;;;;;&c3=4&d1=;;1;2;;;;;;&g=1&a2=1;1;3;2;1;1&l=1&o1=;;;2;;;;;;&z=;;1;1;;;;;;&y1=mappa78&q1=(Shallow)+Berlino&q7=&z6=0.00&e3=YW761OT8B&v1=&v5=No+Limit+0.05%e2%82%ac%2f0.10%e2%82%ac&j1=;;;;;;;;;&i1=;;;0.15;;;;;;&p4=RAKE%3a+0.00&s3=0.10&m1=;;;;;;;;;&f1=;;mappa78;lampolight;;;;;;&d3=YW761OPMI&q4=0.10&y2=0.10&g1=0;0;1.94;2.67;0;0;;;;&b3=0.10&txtTempPot=0.00&n1=;;Fold;;;;;;;&y8=0&n7=1&f3=0&cmd_spos=1&u3=0&s=1&t=0&u=0&e=-1&g2=0&o=-1&f7=0&</vars><commands>Status</commands><SecId/></CMessage>
It seems a xml code UTF-16. Is there a mode to decode this text and make it readble?
Thanks