Send Message in J2ME

May 7, 2008 at 5:14 am (Mobile, Uncategorized)

Sample code for sending a message using J2ME: You can send message with or without port.

MessageConnection smsconn = null;

try {

/** Open the message connection. */

smsconn = (MessageConnection);

TextMessage txtmessage =





} catch (Throwable t) {



if (smsconn != null) {

try {


} catch (IOException ioe) {

System.out.println(“Closing connection caught: “);




1 Comment

  1. Alexwebmaster said,

    Hello webmaster
    I would like to share with you a link to your site
    write me here

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: