Hi,
Code snippets to get phone details and permission required to set
////////code snippets////////////////
Cursor c = getContentResolver().query(People.CONTENT_URI, null, null, null,
null);
startManagingCursor(c);
String[] phonenames = new String[]{People.NAME};
String[] phonenumbers=new String[]{People.NUMBER};
mAdapter = new SimpleCursorAdapter(this,
android.R.layout.simple_list_item_1,
c,
phonenumbers,
new int[] {android.R.id.text1} );
acAdapter = new SimpleCursorAdapter(this,
android.R.layout.simple_list_item_1,
c,
phonenames,
new int[] {android.R.id.text1} );
/////////////////////////////////////////////
Permissions Required:--
<uses-permission android:name="android.permission.READ_CONTACTS" />
//////////////////////////////////////
On Wed, Oct 7, 2009 at 11:44 PM, Samuh Varta <[email protected]> wrote:
>
> Maybe the following could be of some help:
>
> http://www.androidsnippets.org/snippets/108/
>
>
> On Oct 8, 5:04 am, Jeffrey Blattman <[email protected]>
> wrote:
> > is there a way to read the phone's (current) phone number? i realize
> > this would require a permission grant at least.
> >
> > thanks.
> >
> > --
> >
> > --
> >
>
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---