Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

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.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7692703
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T20:54:49+00:00 2026-05-31T20:54:49+00:00

I send from a Service a notification which contents Parcelable ArrayList. //my service code

  • 0

I send from a Service a notification which contents Parcelable ArrayList.

//my service code
Intent intent = new Intent(mContext, AutoSearchActivity.class);

//In this list, there is 3 elements
intent.putParcelableArrayListExtra(Staff.JSON_ARRAY,staffs);

PendingIntent pendingIntent = PendingIntent.getActivity(mContext, 0, intent , 0);

Notification notification = new Notification(
    R.drawable.toplogo, 
    (String) getResources().getString(R.string.notification),
    System.currentTimeMillis());

String titleNotification = (String) getResources().getString(R.string.notification_title);

String textNotification = (String) getResources().getString(R.string.notification_content);

notification.setLatestEventInfo(mContext, titleNotification,textNotification, pendingIntent);

notification.vibrate = new long[] { 0, 400, 100, 400, 100, 600 };

notificationManager.notify(ID_NOTIFICATION, notification);

After cliking on my notification, AutoSearchActivity is executed. I try to catch data and display them, but only old data are displayed. I guess there is a kind of cache system, but I don’t know how to delete it.

//in my AutoSearchActivity
Bundle bundle = getIntent().getExtras();

//only 1 element !!!
ArrayList<SiteStaff> listAppInfo = bundle.getParcelableArrayList(Staff.JSON_ARRAY);

Thank you for your help !

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T20:54:50+00:00Added an answer on May 31, 2026 at 8:54 pm

    Yup , Pending Intent is cached, creates a lot of problems. Change your line to
    PendingIntent pendingIntent = PendingIntent.getActivity(mContext, 0, intent , PendingIntent.FLAG_UPDATE_CURRENT); to force the Pending intent to take the only latest value even if it is fired multiple times.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to send data from an activity to service via intents. This
I have a WCF service that receive query from a silverlight client and send
im want to send notification from my server side (c#) via urbanairship api is
how i can send sms from asp.net?any idea about it?or any resource through which
I’m building email notification service, requirement is to send an email to user when
I am having issue when sending data from Service to Activity through Notification ,
For my iphone game i need to implement a notification service from the server.
Hi i am new to android. I am implementing a code with notification functionality.
I have created one windows service which send an email notifications to users (list
I trying to use apns-csharp library to send push notification from .NET, I created

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.