Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
New Developer
Posts: 18
Registered: ‎02-03-2009
My Device: Not Specified

Storing outgoing messages in the SMS folder

Hello I have a program that sends SMS messages but it's on a Verizon CDMA device so I am forced to use Datagrams. I have a couple of questions.

 

I was wondering if there was an easy way to store my messages in my SMS box like a normal text message would after being sent?

 

Can I make my application push the SMS and MMS folder screen just like a normal SMS or MMS would after sending one?

 

Also the program doesn't have much in the way of error checking except for checking signal strength, is there a way I can add the messages to a que incase the application is closed or the signal is stopped?

New Developer
Posts: 18
Registered: ‎02-03-2009
My Device: Not Specified

Re: Storing outgoing messages in the SMS folder

I think the answer to my first and second question is that I have to make my own storage using PersistantStore but i'm still not sure because I know in the MemoAPIDemo on the JDE it can store memos with what looks like PIMList but there is no PIMList for SMS.

 

I am still curious though, is there anyway to check to make sure my Datagrams are sending? Will I get an IOInturruptedError if something should make the transmission fail?

 

This is all for the Storm, I don't think I mentioned that yet

New Developer
Posts: 18
Registered: ‎02-03-2009
My Device: Not Specified

Re: Storing outgoing messages in the SMS folder

From what i've been reading sending a SMS Datagram should automatically put it in the SMS Outbox but it doesn't, that's wierd.

 

Right now I have a SendingThread that extends thread, it makes a datagram with the message (SMS://234234234 no port because Verizon strips it out from what I heard) so do I need to make a ListeningThread in order for it to see my outgoing SMS messages and place them in my outbox or is this just not possible?

BlackBerry Development Advisor
Posts: 15,727
Registered: ‎07-09-2008
My Device: BlackBerry PRIV
My Carrier: Bell

Re: Storing outgoing messages in the SMS folder

The BlackBerry API set does not provide direct access to read from or write from SMS folders.  The SMS message should appear in the sent folders when sending an SMS message using a MessageConnection without specifying a port, however are not able to use this on CDMA BlackBerry handhelds (where a DatagramConnection should be used).

 

Your application could display the SMS message after it has been sent.  There is no support for viewing such a message in the default Messages application.

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
New Developer
Posts: 41
Registered: ‎04-06-2010
My Device: 9780
My Carrier: Rogers

Re: Storing outgoing messages in the SMS folder

Instead of opening a new topic , I though I'd use this one as my issue is identical to Rogu's.

 

I'm trying to send SMS message through Blackberry Simulator.

I'm using the example from: http://supportforums.blackberry.com/t5/Java-Development/Different-ways-to-send-SMS-messages/ta-p/445...

 

MessageConnection msgConn = (MessageConnection)Connector.open("sms://15195555555");
Message msg = msgConn.newMessage(MessageConnection.TEXT_MESSAGE);
TextMessage txtMsg = (TextMessage)msg;
txtMsg.setPayloadText("Test Message");
msgConn.send(txtMsg);

 

The snippet runs without throwing any exceptions but for some reason, the SMS doesn't show up in the outgoing messages box.  Am I doing something wrong or is this the expected behavior when sending SMS message on Simulator?

 

Thanks

 

 

 

 

Regular Contributor
Posts: 82
Registered: ‎10-28-2010
My Device: Not Specified

Re: Storing outgoing messages in the SMS folder

bug in blackberry, vote to get it fixed
https://www.blackberry.com/jira/browse/JAVAAPI-403