reciving arabic text return ???? with UCS2 encoding

Nov 8, 2011 at 7:08 PM

Hello,

Thanks for this SMPP client library

I have the following problem :

I  connected to SMSC which is sending Arabic text with UCS2 encoding , i recived the text as : ???? in vs2008 ,

so where is the problem and how to fix it  ?

I tried different made ready client software that i noticed it  received the text as the correct as it sent and not : ???? like jamaa client , i think this need some encoding conversion .

Can you help me to return the original text ?

Thanks

Coordinator
Nov 25, 2011 at 4:26 AM

I am not sure why you are getting malformed text. But since other clients worked fine with the same SMSC (as you said), we can suspect a bug during encoding.

I will try to take a look at the source code and see if I can come up with anything useful.

I there a way I can access the SMSC from my end? Or is there a way I can reproduce the error?

If you could send me a binary dump of the PDU that would be very helpful.

Ben

Dec 27, 2011 at 9:42 PM

I solved the same problem with Cyrillic and Hebrew characters by changing all 4 occurrences of

System.Text.Encoding.Unicode

to

System.Text.Encoding.BigEndianUnicode

in the file

JamaaTech.SMPP.Net.Lib\Util\SMPPEncodingUtil.c

 

Hope this helps.

Michael.

Coordinator
Jan 29, 2012 at 6:58 AM

Thanks for sharing this Michael