Search code examples
javaandroidnfcandroid-beam

How can I confirm my message was received using Android Beam?


I'm having success creating an application which sends data through NFC/Android Beam. I am using setNdefPushMessageCallback and wondered how I can detect once the recipient phone has received the message? At the moment, I'm struggling to differentiate between failed and successful beams!


Solution

  • You can register a callback with NfcAdapter.setOnNdefPushCompleteCallback(). It will be called when the transfer via Beam is successful.