How to check a number similar to WhatsApp?

I know this question has been asked before, however, which has not been answered yet, an SMS is sent to your mobile phone and WhatsApp automatically reads the token / authentication code from the sms without requiring the user to enter the authentication code, then WhatsApp automatically enters the authentication code into the EditText area, and then the application installation starts automatically.

Likewise, how my application automatically reads the authentication code from the message and enters that authentication code in the EditText area automatically, after which the application is automatically installed. Any help or guidance regarding this would be much appreciated.

+3


source to share


2 answers


WhatsApp reads your inbox and only finds the message sent, after which Whatsapp extracts the authentication code and displays it in the view.

To implement such a function, you need to write the received broadcast, which will receive information about the receipt of any SMS message, and then you can filter this message to get an authentication code.



Refer to this article. http://androidexample.com/Incomming_SMS_Broadcast_Receiver_-_Android_Example/index.php?view=article_discription&aid=62&aaid=87

+4


source


set broadcast receiver to receive call when receiving SMS

 <intent-filter>
            <action android:name="android.provider.Telephony.SMS_RECEIVED" />
 </intent-filter>

      



Then read the post for the code.

0


source







All Articles