java - Get complete path from URI - Nexus specific -


we have code running convert local uri path complete path. code doesn't seem work on nexus series (android 4.1+ jelly bean).

code

string[] proj = { mediastore.images.media.data }; cursor cursor = app.getinstance().getcontentresolver().query(contenturi, proj, null, null, null); int column_index = cursor.getcolumnindexorthrow(mediastore.images.media.data); cursor.movetofirst(); return cursor.getstring(column_index); 

i've read various thread on stackoverflow , relative 1 this one. solution provided in issue still persisting.

basically path returned code this: /storage/emulated/0/folder_we_are_trying_to_access

but in nexus there no emulated storage. trying see path various file managers seems path is:

/storage/sdcard0/folder_we_are_trying_to_access

any appreciated. in advance.


Comments

Popular posts from this blog

javascript - DIV "hiding" when changing dropdown value -

Does Firefox offer AppleScript support to get URL of windows? -

android - How to install packaged app on Firefox for mobile? -