How to send SMS programmatically in BlackBerry?
And I read somewhere, I need server side as well as client side code for sending SMS. Is it true? For sending message from 1 device to another or from Emulator to device, Do I really need server side as well as client side code?
I found this code somewhere for client side, but I am not getting output.
private void sendSMS(String phone, String message) throws RuntimeException, ServicesManagerException, IOException
{
// TODO Auto-generated method stub
System.out.println("in send sms function");
MessageConnection conn =
(MessageConnection)Connector.open("sms://+919099087960");
BinaryMessage msgOut = (BinaryMessage) conn.newMessage(MessageConnection.BINARY_MESSAGE);
msgOut.setPayloadData("my binary payload".getBytes("UTF-8"));
conn.send(msgOut);
}