0

The getExternalStorage() now in 4.4A, points to the emulated storage...Since the base android phones donot have the option of external sdcard, and the other phones have that option, is there any way to get the path of the external sdcard?

Many Thanks in advance,

  • What do you mean by `is there any way to get the path of the external sdcard?` ? The `getExternalStorage()` return the path of the sdcard only. – GrIsHu Dec 18 '13 at 04:52
  • `Environment.getExternalStorageDirectory().getAbsolutePath();` is not working? – Abhishek V Dec 18 '13 at 04:52
  • In android4.4 getExternalStorage() does not return the path of sdcard. and Environment.getExternalStorgeDirectory().getAbsolutePath() not working.. – user3113789 Dec 18 '13 at 04:54

1 Answers1

0

Use this:

new File("/mnt/external_sd/");

OR

new File("/mnt/extSdCard/");

in your case...

in replace of Environment.getExternalStorageDirectory()

Avijit
  • 3,834
  • 4
  • 33
  • 45
  • Thanks...But want to change from the init.rc files level. – user3113789 Dec 18 '13 at 04:56
  • I just need to get the path of the external sdcard. The code of Kitkat by default now points to the internal memory. Since the customized phones do not have huge internal mem like base android phones, and all the functions that used to point to external sdcard have now been made to point to internal memory,(they have designed it the like this, keeping base android phones in mind), i do not have any option to get the sdcard path. Pl help for the same... – user3113789 Dec 18 '13 at 05:16
  • have a look on this: http://stackoverflow.com/questions/11281010/how-can-i-get-external-sd-card-path-for-android-4-0 – Avijit Dec 18 '13 at 05:18
  • If this answer help you please accept it and close the topic. – Avijit Dec 18 '13 at 06:02