I used FileInputStream class when I was trying to read something from my files reside in SDCard, the codes are as follows: Code:
filepath = "/sdcard/myfile/testFile" FileInputStream fileIn = null;
fileIn = new FileInputStream(filepath); byte [] InBuf = new byte[1024];
fileIn.read(InBuf); Strubg fileContent = new String(InBuf);
fileIn.close();
when I ran my program, android keep reporting null pointer error on my last line:"fileIn.close", I really didn't know the reason