This is just a wild guess but maybe you need to use two intents (first a
contacts intent and then a phone intent passing in the contact id).
http://code.google.com/android/reference/android/provider/Contacts.Phones.html

On Tue, Dec 30, 2008 at 5:54 PM, Sarath Kamisetty <
[email protected]> wrote:

>
> Hi,
>
> The following worked for me
>
>        Intent i = new Intent(Intent.ACTION_PICK,
> Uri.parse("content://contacts/people"));
>        startActivityForResult(i, CONTACTS_PICK_REQ);
>
> in my onActivityResult, I extract the picked URI like below:
>
>    protected void onActivityResult(int requestCode, int resultCode,
>                                        Intent intent) {
>        Uri pickedContact;
>
>        super.onActivityResult(requestCode, resultCode, intent);
>        if ((requestCode == CONTACTS_PICK_REQ) && (resultCode == RESULT_OK))
> {
>                pickedContact = intent.getData();
>        }
>    }
>
> However this didn't quite solve the problem for me. What I want is to
> let user pick a contact *and* then select one of the home/mobile/work
> numbers. I am not sure how to proceed from this point onwards where I
> have URI for contact. Is there a way to let user first pick a contact
> in one screen and then display all his numbers in another screen and
> let user pick one of those numbers ?
>
> Thanks,
> Sarath
>
> On Mon, Dec 29, 2008 at 11:38 AM, Mark Murphy <[email protected]>
> wrote:
> >
> > Binesy wrote:
> >> Hi
> >>
> >> I was wondering is it posible to launch other applications within an
> >> activity, such as the native contacts application?  If so how do you
> >> do this?
> >
> > startActivity(), with an Intent that will launch whatever it is you
> > want. For example, if you want the user to choose a contact, you would
> > use an ACTION_PICK Intent with the contacts Uri.
> >
> > --
> > Mark Murphy (a Commons Guy)
> > http://commonsware.com
> >
> > Android Training on the Ranch! -- Mar 16-20, 2009
> > http://www.bignerdranch.com/schedule.shtml
> >
> > >
> >
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" 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-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to