What would be the开发者_如何学C best way to build a sms application with adobe AIR and AS3? An application that send and receive sms. I found how to send using the uri but can't find any explanations about how to receive and display it.
This cannot be done with the latest version of AIR 2.6. AIR mobile API only allows you to send text messages but does not allow you access to the contacts list or received messages. Your best bet would be to switch over to the native APIs to be able to receive messages (i.e. use the Telephony.SMS_RECEIVED
intent). However, AFAIK, access to sms inbox is deprecated in the latest native SDK.
I've heard that some future version of AIR may support native extensions which might come handy (to access contact list, inbox etc.) but no dates. So once again, you're best served to switch over to the native API.
Here's an idea you may consider: write a small native server that would read off of the inbox (provided that is possible/listen to the sms receipt notifications) and forward the data to your AIR/Flex app over a socket. Disclaimer: Haven't tried this out myself, so all bets are off.
If you register the AIR application for the sms: intent (which might be the "sms inbox" dirk mentioned), then you will at least get the notification.
Cheers
精彩评论