I\'m wondering if I am understanding the concepts of requestCode correectly. What is this integer for and does it matter what integer I set it to in:
public void onActivityResult(int requestCode, int resultCode, Intent data)
app
receives results from the different intents
via above method only. So how will you understand which intent had replied to you? For that reason, before invoking the intents we put a self defined TAG/Label which is called requestCode
. By our own defined requestCODE
we can check which intent's result we have received.
Here in requestCode
in the example I have given 1001 for Camera Intent. You can put any of your desired number. 1200 or 2001 or 21. Any Positive integers ranging to ~2^16.
See the picture attached.