ok, my test file was too small. With a bigger file it works.
But the access token that i used is my accesstoken for developer and so destination path goes to my account (developer) and not in account of user that use the app on the phone.
Where is the error? if i don't use accesstoken, i've a "bad request" for error in http authentication..
I need that destination path is in the user dropbox and not in my developer account.
thanks
B4X:
In Sub Activity_Create(FirstTime As Boolean)
'--- DROPBOX --------------------------------
If FirstTime = True Then
clientID = "yyyyyyyyyyyy"
accesstoken = "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" ' my dev token
End If
'--------------------------------------------------------------------------
B4X:
in Sub backupDB_Dropbox
Log("backupDB_Dropbox")
dbx.Initialize(Me,"DropBox",accesstoken,True)
...
B4X:
in Sub uploadFile
pws.KeepAlive(True)
Dim session As Map
session.Initialize
session.Put("srcpath",zipDestinationPath)
session.Put("srcfile",modGeneral.dropbox_remoteFileName)
session.Put("dstpath","/mylifebook")
session.Put("dstfile",modGeneral.dropbox_remoteFileName)
session.Put("offset",0)
session.Put("packetsize",16384)
dbx.UploadSessionStart(session)