String encoding

Hi all,

I use a webservice by mobile calling it. in the mobile I enter data and send it as a string to the webservice.

The mobile deal with the data as UTF-8. when I send the string to the webservice I recieve marks. what can be the problem

What is the encoding method in the webservice side

The string in the mobile looks like: "\u12EA\u23SE..."

How can I check the encoding method.

Please help...



Answer this question

String encoding

  • pserranop

    Hi,

    Thanks for reply...

    In the mobile application I send a string with hebrew letters. The big problem that I can't see the real values arrive to the webservice by debuging.

    What do you suggest to do for watching the incoming string to the webservice

    If I send English letters every thing is fix, so there is no problem with the display. I think the main problem in the Hebrew font letters.

    I want to add, I had a problem with the first direction, I mean sending hebrew strings from the webservice to the mobile, than I translate the string to UTF-8 in the mobile and the problem was fixed. By I didn't know whitch formate the string came to the mobile.

     

    Please help.

    Best regards...


  • jack zareba

    You should not use UTF-8 encoding in the application: all stings should be send as Unicode.

    What kind of problem you had with receiving Unicode strings from webservice

    Thanks,

    Elena


  • Boomstik

    It sounds like you are getting the string on the service but when you display it you see question marks.  Is that correct   Have you checked the actual unicode values for the string to make sure that they are the same as the sent string   Could it be that you received the correct string but it's just not displaying correctly

    Daniel Roth



  • yanke

    I ran into a similar situation awhile back.  I have yet to find a solution to the problem.

    What I think was happening was that the wierd characters breaks the SOAP-XML serializer.  As we our client app was a Windows Form, our workaround was to first encapsulate the message in a dataset.

    You should be able to debug the webservice simply by setting a breakpoint at the beginning of the web method.

    Otherwise, I just found this HTTP tracer for another problem, which might work in your situation as well: http://www.ieinspector.com/httpanalyzer/

    Good luck.


  • String encoding