I need to send data from EditText in activity A to Activity B.
I tried:
Intent intent1=new Intent(A.this,B.class);
intent1.putExtra("fromA", "text");
startActivity(intent1);
But It doesn’t work, because activity B has android:launchMode="singleTask" and was created before.
How else, can I send data?
You override
onNewIntent()in theActivity Band receive theintentin that method.Like below code:
In the above code you will get value to
sfromActivity A.