So I can display Android’s contact selecton activity by calling
startActivityForResult(intent, PICK_CONTACT);
and i can get the selected contact by overriding onActivityResult
public void onActivityResult(int reqCode, int resultCode, Intent data) {
super.onActivityResult(reqCode, resultCode, data);
}
Trouble is onActivityResult is only available when I am calling from an Activity myself. If I am in a DialogPreference for instance how would i get at the selected contact because I do not have an onActivityResult to override ?
TIA
Pat Long
I know you want to create a custom DialogPreference to Pick a Contact as proposed in the other question, you indeed need to launch the intent to pick the contact and get the result.
I see you need to create a private class that extends Activity in your own DialogPreference class. And you will use that class and the onActivityResult.
You are doing a great job, keep up the good work.