开发者

sending image to dropbox folder in android

开发者 https://www.devze.com 2023-04-03 13:31 出处:网络
i need to send image to my folder which is in dropbox. i already sent a .txt file with following statement

i need to send image to my folder which is in dropbox. i already sent a .txt file with following statement

int putFileResult = api.putFile("dropbox", "/Foldername", file);

Now i have to send image from SD card, how can send image to dro开发者_如何学Pythonpbox, how to do this.

i have found some solution to send thumbnails in this link

but it didnt solved my problem. please tell me the way to send images

thanks in advance


FileInputStream fis = new FileInputStream(mFile);
String path = mPath + mFile.getName();
mRequest = mApi.putFileOverwriteRequest(path, fis, mFile.length(), new ProgressListener() {

    @Override
    public long progressInterval() {
        return 500;
    }

    public void onProgress(long bytes, long total) {
        publishProgress(bytes);
    }
});

if (mRequest != null) {
    mRequest.upload();
    return true;
}
0

精彩评论

暂无评论...
验证码 换一张
取 消