if(new File("/mnt/sdcard/t.m").exists()) {...}
When I create a java program using Eclipse and debug it on my Android phone, it tests right. But when I put it into a app in my Android system, it does not detect the file.
And, in another app (built in my Android system, too), though I've put following in AndroidManifest.xml,
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
the code below causes an exception saying no permission,
File f=new File("/mnt/sdcard/a.t"); f.createNewFile();
Thank you. I'm new to Android.