Created
April 11, 2011 10:31
-
-
Save paddycarver/913336 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void sdCardMountCheck() { | |
String state = android.os.Environment.getExternalStorageState(); | |
if(android.os.Environment.MEDIA_MOUNTED.equals(state)) { | |
sdCardReadable = true; | |
sdCardWritable = true; | |
}else if(android.os.Environment.MEDIA_MOUNTED_READ_ONLY.equals(state)) { | |
sdCardReadable = true; | |
sdCardWritable = false; | |
}else{ | |
sdCardReadable = false; | |
sdCardWritable = false; | |
} | |
Log.e("completeandroid", sdCardReadable+"|"+sdCardWritable); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment