Hi i try sen sms with this code , but invalid port error shown
try {
MessageConnection mc = (MessageConnection) Connector.open("sms://0123456789");
TextMessage msg = (TextMessage) mc.newMessage(MessageConnection.TEXT_MESSAGE);
msg.setPayloadText("salam");
mc.send(msg);
mc.close();
} catch (IOException ex) {
ex.printStackTrace();
}
what is wrong in my code ?