0

Like the Title,I feel puzzled about that. eg:

Uri contactData = data.getData();
String [] projection ={Phone.NUMBER};
Cursor c = getContentResolver().query(contactData, projection, null, null, null);
c.moveToFirst();
int column = c.getColumnIndex(Phone.NUMBER);
String num = c.getString(column);  
Konstantin Yovkov
  • 60,548
  • 8
  • 97
  • 143
JohnTsai
  • 5
  • 1

1 Answers1

0

The Cursor you get from query starts out before the first record.

So in order to use it, you need to put it somewhere.

Thilo
  • 250,062
  • 96
  • 490
  • 643