I would like to know what are the options for intercepting an SMS. I want to be able to launch some code to handle the SMS when it is received. Any advise on whether this is technically possible and what options I have if there is more than one way, would be greatly appreciated.
Thanks Paul
in blackberry you can attach message listener to specific port.
port=0 means you can listen for all default incoming sms.
if you attach the message listener to port other than 0, message will not appear in inbox. but if you failed to handle this message, it will appear in inbox.
some restrictions are there for message listeners.
Since you have so many tags, it's hard to tell which OS you're actually developing for. On the iPhone, you cannot "snoop in" on SMS messages without the help of a patched Kernel (jailbreak).
At blakberry you also can not spy on SMS messages, which run on standard port.
I can speak for Symbian C++ only. And good news - it's possible.
You can use this code example if you want to be notified of all changes in the inbox folder: http://wiki.forum.nokia.com/index.php/CS001416_-_Listening_for_incoming_SMS_messages
Or this example it you want to intercept messages sent to a particular port or only messages that match some text pattern: http://wiki.forum.nokia.com/index.php/SMS_Utilities_API
If you don't want the intercepted message to appear in the inbox folder use the second example.
For Windows Mobile it's quite easy to intercept SMS messages using the MessageInterceptor class. MSDN even has an article covering how to use it.