BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 12-08-2009, 06:37 AM   #1 (permalink)
New Member
 
Join Date: Dec 2009
Model: 9000
PIN: N/A
Carrier: Airtel
Posts: 4
Post Thanks: 0
Thanked 0 Times in 0 Posts
Question Text Message/SMS code not working

Please Login to Remove!

I am trying to send SMS through from a BlackBerr(BB) application. I am tring following process:

Thread t = new Thread(this);
t.start();
public void run(){

String address = "sms://1234567890";

MessageConnection smsconn = null;

try {
smsconn = (MessageConnection) Connector.open(address);

TextMessage txtmessage = (TextMessage) smsconn.newMessage(MessageConnection.TEXT_MESSAGE) ;
txtmessage.setAddress(address);
txtmessage.setPayloadText("SMS sending suceessfull");

smsconn.send(txtmessage);

} catch (Exception t) {
System.out.println(t.getMessage());
Dialog.alert(t.getMessage());
System.out.println(t.getClass().getName());
}

if (smsconn != null) {
try {
smsconn.close();
} catch (IOException ioe) {
System.out.println(ioe.getMessage()); }
}

}
}

The message is not getting send and no error is displayed.


PLease help!!!!!
Offline  
Closed Thread


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

6pcs microchip pic18f67j60 eeprom 23k256 net Ethernet Board pcb diy 6pcs
$12.0
6pcs microchip pic18f67j60 eeprom 23k256  net Ethernet Board pcb diy 6pcs picture20x 24WC02 SMD SO8 2k (256x8) EEPROM CATALYST (A-1352)
$1.43
20x 24WC02 SMD SO8 2k (256x8) EEPROM CATALYST (A-1352) picture20x 24C32 SMD SOIC8 32k EEPROM MICROCHIP (A-1677)
$1.43
20x 24C32 SMD SOIC8 32k EEPROM MICROCHIP (A-1677) picture20x 24C08 SMD SO8 8k (4x256x8) EEPROM STM (A-1415)
$1.43
20x 24C08 SMD SO8 8k (4x256x8) EEPROM STM (A-1415) picture99-PCS IC 93LC56B-I/SN EEPROM 2KBIT 2MHZ 8-PIN SOIC MICROCHIP 93LC56 93LC56BISN
$13.35
99-PCS IC 93LC56B-I/SN EEPROM 2KBIT 2MHZ 8-PIN SOIC MICROCHIP 93LC56 93LC56BISN picture






Copyright 2004-2016 BlackBerryForums.com.
The names RIM and BlackBerry are registered Trademarks of BlackBerry Inc.