Ok… so i guess the title is a bit confusing. so i will explain:
I have an NFC app which i handle a NDEF_DISCOVERED succesfuly in activity A. then a new activity is launched (B).
In this new activity (B) i want to be able to catch another tag and let activity A handle it as before, so i use OnNewIntent to get this intent of the tag and want to start activity A.
But if i call startActivity(myIntent) with the traditional myIntent = new Intent(this, A.class) then activity A launced with this myIntent and i want the activity A to handle the tag intent that was ‘caught’ on activity B..
how can i do that?
Thanks.
You should be able to add your tag intent in activity B as an extra to the traditional intent with myintent.addExtra(“tagkey”, tagIntent). Because Intent implements Parcelable, it will be added as a Parcelable extra. Then in the onCreate() of activity A, put something like:
Replace the string “tagkey” with whatever is most relevant to your own code. You can put a similar snippet in onNewIntent() as well.