thanks is working now, it was exactly what you said, I was looking into Intent and put/get Extras... I had no clue of this PendingIntent behavior.
On Jan 9, 10:06 pm, Mark Murphy <mmur...@commonsware.com> wrote: > Albert wrote: > > Hi, > > > Can someone see what I am doing wrong here, when I try to get the > > extras I sent on my intent it always returns null > > > Intent activityIntent = new Intent(context, TopImage.class); > > activityIntent.putStringArrayListExtra("com.mobile.dev.LIST", > > mStringList); //mStringList is not null for sure > > > > // > > "com.mobile.dev.LIST" my package prefix+keyname > > then to extract the data: > > > //this is done in onCreate() > > ArrayList<String> t = new ArrayList<String>(); > > t = getIntent().getStringArrayListExtra("com.mobile.dev.LIST"); // it > > is always returns null, I get an null pointer exception as soon as I > > use t. > > > The intent is sent from a widget which launches the activity from > > which i am trying to get this Extra... > > If you are wrapping this in a PendingIntent, that may be the source of > your difficulty. Make sure your previous PendingIntent is canceled > before creating a new one with a new extra. > > -- > Mark Murphy (a Commons > Guy)http://commonsware.com|http://twitter.com/commonsguy > > Android Training in US: 8-12 February 2010:http://bignerdranch.com
-- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en