BlackBerry Forums Support Community               

Closed Thread
 
LinkBack Thread Tools
Old 03-18-2010, 05:33 AM   #1 (permalink)
Knows Where the Search Button Is
 
Join Date: Dec 2009
Model: 7100T
PIN: N/A
Carrier: java
Posts: 31
Post Thanks: 0
Thanked 0 Times in 0 Posts
Default SMS sending : NullPointerException

Please Login to Remove!

Hello to all,

i am working on one applicaion in which i have to send SMS through programme but whenever i am using the below code to send the message then i am getting the NullPointerException on Invoke.invokeApplication method.

TextMessage msgout;
MessageConnection msgcon;
msgcon = (MessageConnection)Connector.open("sms://");
msgout = (TextMessage) msgcon.newMessage(MessageConnection.TEXT_MESSAGE);
msgout.setAddress("sms://15198887465");
msgout.setPayloadText("I am busy. Call u later");
Invoke.invokeApplication(Invoke.APP_TYPE_MESSAGES,
new MessageArguments(msgout));
msgcon.send(msgout);


can anybody tell me that what is the problem.

with thanks and regards
Shakeel
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

Used SIEMENS 6ES7223-1PL22-0XA8 Extension module Tested
$116.0
Used SIEMENS 6ES7223-1PL22-0XA8 Extension module Tested picture1PCS NEW Siemens 3TK2825-1BB40 Safety Relay 24VDC
$355.0
1PCS NEW Siemens 3TK2825-1BB40 Safety Relay 24VDC pictureUsed SIEMENS 6ES7 151-1AA05-0AB0 Interface Module Tested
$175.0
Used SIEMENS 6ES7 151-1AA05-0AB0 Interface Module Tested pictureED42B090 NEW IN BOX - Siemens Circuit Breaker - Free UPS Ground
$170.0
ED42B090    NEW IN BOX - Siemens Circuit Breaker - Free UPS Ground pictureNEW FOR SIEMENS 6ES7291-8BA20-0XA0 6ES7 291-8BA20-0XA0 S7-200
$21.0
NEW FOR SIEMENS 6ES7291-8BA20-0XA0 6ES7 291-8BA20-0XA0 S7-200 picture






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