naresh
naresh

Reputation: 10392

android- How to use startActivityforResults() in tabs

I am new to tabs concept. In my app one tab have the navigation to the multiple Activities. Here some cases I need the result of the child activity so I want to use the startActivityforresult() method. I tried I am not getting please can anybody help me.

code

Intent intent = new Intent(getParent(), RB_StateMList.class);       
startActivityForResult(intent,GET_SEL_STATES_LIST); 

Upvotes: 0

Views: 269

Answers (1)

waqaslam
waqaslam

Reputation: 68167

You need to override onActivityResult in either your Activity or ActivityGroup in order to receive results back from other activity. See below:

@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
    // TODO Auto-generated method stub
    super.onActivityResult(requestCode, resultCode, data);
}

Upvotes: 1

Related Questions