Passing parameters to new Activity

by vincent.gann...@gmail.com » Tue, 03 Mar 2009 02:52:03 GMT


Sponsored Links
 Hi all,

I'm programming an Activity that launches a second one through
startActivity just like in the Forwarding example. The main difference
is that I'd like to pass some data to the second Activity when
starting it, for example an item selected in a list owned by the first
Activity. I can't find how to do that... Am I missing something? I
guess I do.

Thank you for helping me.

--~--~---------~--~----~------------~-------~--~----~



Passing parameters to new Activity

by Marco Nelissen » Tue, 03 Mar 2009 03:08:45 GMT


 You can add 'extras' to the Intent that you use to start the 2nd Activity.


On Mon, Mar 2, 2009 at 8:34 AM, vincent.gann...@gmail.com



--~--~---------~--~----~------------~-------~--~----~


Sponsored Links


Passing parameters to new Activity

by vincent.gann...@gmail.com » Fri, 06 Mar 2009 21:46:36 GMT


 Works fine! Thanks Marco.
--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. Lost with custom drawable animation

Hi everyone,

I'm currently developing an application with custom drawables and i'm
kind of lost.
I do not use XML since all kind of the parameters have to be computed
on the fly.
I have a main custom view holding all the gui.
I made a class mcDrawable extending drawable implementing
Drawable.Callback.
In its draw method, i draw a couple of primitive (circles, and so on)
An instance of mcDrawable is displayed via the onDraw method of the
view.

When I trigger a motionEvent in the view, it calls a certain method in
an instance of mcDrawable which modifies the shapes. Since I call an
invalidate() after each event in the view, the drawable is updated
nicely during the motion. So far, all is good.

When I stop the motion (ACTION_UP), it triggers another method in the
instance of mcDrawable which send a message to an Handler in
mcDrawable which animate it by the mean of delayed messages. However,
the View is not aware of these changes and therefore, does not redraw
the drawable.
To achieve the proper behavior, i made the view static, with a
Handler, and send a message from mcDrawable Handler to the one of the
view. When the view receive it, it invalidates. However, I don't think
that its the proper way to achieve this !

So my question is the following: is there a proper way for mcDrawable
to ask the View to redraw it, by the mean of Drawable.Callbacks for
example ? I understand that it may use a selfInvalidate() in
mcDrawable, but I don't understand how to link it to the view. Could
someone help me ?

Thanks !

-- 

2. Accessing external USB storage

Are there  Android API's  to access data from an external USB device,
such as a hard drive?  I need to write an app to interface with an
external usb device, is this possible?  What system calls are used?

-- 

3. Problem in Compiling android-2.6.32 kernel

4. Charger

5. virus di nexus

6. Android Geolocation app, Find if a user is facing a certain Location using Digital Compass.

7. OOT : Test Running Cynogen