onReceive (Context context, Intent intent) in B & C with two calls
from A

one each to B & C from A and A with have to register a "callback
reciever" (as it seems to be called by coders ) with something like
registerReceiver (BroadcastReceiver receiver, IntentFilter filter)
before calling sendBroadcast (Intent intent) from what ( i think - i
am new at this ) the SDK is calling android app Activity which is
(rather obviously) the entry for "doing something" (by the user of the
device)

in general, the form of what you need is often called callbacks or
interfaces ~ take awhile for one to grasp that we write a code-path
for the instruction pointer to follow - we are not actually "driving"
the code nor does the code drive the machine = we are only describing
a path

this is done with callbacks and interfaces ~ to do it like your first
approach it is needful to pass a ref from A to B&C so the thread there
can "callback" ~ which works but correct design is to let the SKD tell
us how to do it as most hardware vendors will (likely) have someone
code it from there end where onLowMemory() and so on may intercede if
needed as the way the coder does it may tend to load the machine when
user may suddenly decide to do something else

On Oct 29, 2:08 pm, John Goche <[email protected]> wrote:
> Hello,
>
> I have come across the following scenario: I have an activity A which
> needs to launch activity B to make a selection. The selected value
> eventually needs to be passed back to A, but before that happens,
> selecting the value from activity B launches another activity C. When
> a selection is made on activity C both selected values from B and C
> are passed back to A.
>
> So now I am wondering what the best way to code this is. Do I use
> finishActivity() or just call finish() in activity B when its
> onActivityResult()
> is called? Suggestions welcome. Basically I would like to rid myself of
> both popup windows when a selection in the latter is made.
>
> Thank you for your input,
>
> John Goche

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to