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;

}

arrow
arrow
    全站熱搜

    fabch2 發表在 痞客邦 留言(0) 人氣()