private byte[] getPhoto(String name) {
FileInputStream fis = null;
byte[] b = null;
try {
fis = new FileInputStream(name);
int totalBytes = fis.available();
b = new byte[totalBytes];
fis.read(b);
} catch (IOException ex) {
}
try {
fis.close();
} catch (Exception ex) {
}
return b;
}
全站熱搜