Hello,

If I try to use the code below to read characters that is sended from
C# to an Android phone I get problem reading specials signs for
example swedish letters like ÅÄÖ gets abit wierd.

Do anyone have some tips for me that I can change here to enable to
get special signs? ( The code below works on a normal java application
but not on android platform) (The text I send is sended from C# to
Android JAVA.).

If someone have any pointers to give me I would be happy.


    try {
      ServerSocket ss = new ServerSocket(1234);
      Socket test = ss.accept();
      InputStream is = test.getInputStream();
      DataInputStream dis = new DataInputStream(is);
      char c = dis.readChar();
      while (c != -1) {
        System.out.print("Read char = " + c);
        c = dis.readChar();
      }
      System.out.print("Read char = " + c);
    } catch (IOException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
    }

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to