I have three activity, eg. A, B and C. A start B, and B start C. I will remove B from the back stack in C. Then I need to pass some data from C to A before I finish C. My question is how to pass data from C to A ?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If you want to pass some data from C to A before finishing C activity then you can use broadcast receiver in your A activity and can send broadcast from C to A directly.
Write the below code before starting activity B from A. This code will receive data from activity C.
Write this code to send data from activity C to activity A.
Hope it will help you if it is not working then tell me the problem you are facing. I think it should work.