I want to read the message body of a new incoming SMS in android, programmatically.
I tried something but that doesn\'t return any contents:
A very easy solution would be to use this SMS Parser library:
https://github.com/adorsys/sms-parser-android
compile 'de.adorsys.android:smsparser:0.0.3'
Using it you can either read the whole message, or specific parts of the incoming message. You can also set the phone numbers from which the message will be coming.
If you need more info about how it works or its usage check the github repository I listed above.