RMK
RMK

Reputation: 819

Read mail Attachment files in Android2.1?

I configure email by using the android2.1 emulator. When I download the files from mail attachment I get the path content://com.android.email.attachmentprovider/1/1/RAW

I need to read that file data. How to read the data from the device.?? Is there any permission to read file from the phone memory. My code is here:

 intent = getIntent();        
 String str_sel_fname=intent.getDataString();

In the eclipse file explorer /data/data/com.android.email/databases/1.db_att/1

here 1 is store the attachment file .Now can anyone help me to get the data from that.??

Upvotes: 2

Views: 10810

Answers (1)

CommonsWare
CommonsWare

Reputation: 1007276

Try getContentResolver().openInputStream(). openInputStream() on ContentResolver should give you an InputStream on that content Uri.

Upvotes: 1

Related Questions