0

How to pass value of notification's when one row is clicked ,to another activity for displaying details in android?

1 Answer 1

2

Check this out:

Notification n = new Notification(icon, text, when);
String contentTitle = "I am expanded title";
String contentText = "I am expanded text";
Intent intent = new Intent(this, TargetActivity.class);
// Put additional stuff into the created intent
PendingIntent contentIntent = PendingIntent.getActivity(this, 1, intent, 1);
n.setLatestEventInfo(this, contentTitle, contentText, contentIntent);

Put your information in the intent, using Intent.putExtra methods, and retrieve them in the target activity.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.