The code looks good AFAICT. Please give the actual before/after characters that are coming out wrong. For example, try the Ethiopian syllable qu, U+1241. If it's coming across as a box followed by an "A", then the receiver has gotten two characters, U+0012 and U+0041. I really need to see the hexadecimal data in your sent and received SMS messages to figure out what's going wrong.
I would also suggest that using the debugger or android.util.Log, instead of Toast, would be a better way to debug. On Thu, Dec 31, 2009 at 2:26 AM, andu <[email protected]> wrote: > To send the message I have used the following function: > > public boolean sendSMSMessage(String compiledContent, String > DistinationAddress) > { > String receiverPhoneNumber = DistinationAddress; > String messageCenterPhoneNumber = ""; > SmsManager smsMgr = SmsManager.getDefault(); > smsMgr.sendTextMessage(receiverPhoneNumber, null, > compiledContent, > null, null); > return isSent; > } > > To receive the message I have used the following function: > > > @Override > public void onReceive(Context context, Intent intent) { > Bundle bundle = intent.getExtras(); > > if(bundle != null) > { > Object messages[] = (Object[]) bundle.get("pdus"); > SmsMessage smsMessage[] = new SmsMessage[messages.length]; > for (int n = 0; n < messages.length; n++) > { > smsMessage[n] = SmsMessage.createFromPdu((byte[]) > messages > [n]); > } > > // show first message > Toast toast = Toast.makeText(context, " Brhp Received SMS: " > + smsMessage[0].getMessageBody()+ "from " + smsMessage > [0].getOriginatingAddress(), Toast.LENGTH_LONG); > toast.show(); > > > String messageBody = smsMessage[0].getMessageBody(); > String messageSource = > smsMessage[0].getOriginatingAddress(); > } > > > } > > > > > > > > On Dec 29, 1:02 am, andu <[email protected]> wrote: > > How are you all? > > > > I am developing application for android phone. Currently I am testing > > my system in the emulator. In my application, I want to send unicode > > character (Amharic language character) via SMS to the other emulator > > instance. But in the receiver side, the message is not viewed > > properly. I think the problem is some character encoding related > > problem. > > > > In addition similar problem happens for texts which are queried for > > the sqlite database. that is when I send a query result via SMS the > > same problem occurs. Please help me. > > > > Sorry for posting the same message again. Please help me. > > > > Thank you > > > > Andu. > > -- > 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]<android-developers%[email protected]> > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en > -- 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

