Hi,
I'm trying to upload photos to Dropbox account using v2.
FileStream fsBlobData = new FileStream(filePath, FileMode.Open, FileAccess.Read);
byte[] bytBlobdata = new byte[fsBlobData.Length];
using (var dbx = new DropboxClient(accessToken))
{
using (var stream = new MemoryStream(bytBlobdata))
{
var response = await dbx.Files.UploadAsync("/"+ folder + "/" +
fileName, WriteMode.Overwrite.Instance, body: stream);
return response;
}
}
But after uplaoding when i try to preview file it says "This file can’t be previewed".
My original file is 129kb and uploaded is 129.19kb.
Then i have downloaded the same file from Dropbox itself and try to open with windows image viewer but windows photo viewer can't open this picture.
Please tell me what i'm doing wrong here.
Thank you.