Monday, 19 August 2013

determine if android activity was opened "for result"

determine if android activity was opened "for result"

in some instances I want my activity (activity A) to setResult and other
times I want my activity to startActivity and sent an intent with some
parameters while calling finish on itself.
I can solve this problem by starting this activity A with some bundle
paramaters, if that parameter exists then setResult else startActivity but
now I am curious if there is anyway to check the intent for how it was
started in the first place
Is there a way to determine if my activity A was started for result?

No comments:

Post a Comment