Dropbox Sync Library

Mahares

Expert
Licensed User
Longtime User
DropBox allows files upload with only the following file extensions (see list below). If your extension is .db, .db3, or Sqlite3, it will not allow you the upload. In that case, you need to contact their tech support via their site and request that they add , for example .db to your application. They will do it. I had them do the same thing for me. I have requested that they add the extension universally since .db is a very popular extension, but they only did it to my specific application.

File type
The File type permission gives your app access to all files of a specific type (such as text or image files) across a user's entire Dropbox. You can choose any type appearing in the list below.

  • Text files .applescript, .as, .as3, .c, .cc, .clisp, .coffee, .cpp, .cs, .css, .csv, .cxx, .def, .diff, .erl, .fountain, .ft, .h, .hpp, .htm, .html, .hxx, .inc, .ini, .java, .js, .json, .less, .log, .lua, .m, .markdown, .mat, .md, .mdown, .mkdn, .mm, .mustache, .mxml, .patch, .php, .phtml, .pl, .plist, .properties, .py, .rb, .sass, .scss, .sh, .shtml, .sql, .tab, .taskpaper, .tex, .text, .tmpl, .tsv, .txt, .url, .vb, .xhtml, .xml, .yaml, .yml, and files with no extension
  • Documents .csv, .doc, .dochtml, .docm, .docx, .docxml, .dot, .dothtml, .dotm, .dotx, .eps, .fdf, .key, .keynote, .kth, .mpd, .mpp, .mpt, .mpx, .nmbtemplate, .numbers, .odc, .odg, .odp, .ods, .odt, .pages, .pdf, .pdfxml, .pot, .pothtml, .potm, .potx, .ppa, .ppam, .pps, .ppsm, .ppsx, .ppt, .ppthtml, .pptm, .pptx, .pptxml, .prn, .ps, .pwz, .rtf, .tab, .template, .tsv, .txt, .vdx, .vsd, .vss, .vst, .vsx, .vtx, .wbk, .wiz, .wpd, .wps, .xdf, .xdp, .xlam, .xll, .xlr, .xls, .xlsb, .xlsm, .xlsx, .xltm, .xltx, .xps
    • Images .bmp, .cr2, .gif, .ico, .ithmb, .jpeg, .jpg, .nef, .png, .raw, .svg, .tif, .tiff, .wbmp, .webp
    • Videos .3g2, .3gp, .3gpp, .3gpp2, .asf, .avi, .dv, .dvi, .flv, .m2t, .m4v, .mkv, .mov, .mp4, .mpeg, .mpg, .mts, .ogv, .ogx, .rm, .rmvb, .ts, .vob, .webm, .wmv
    • Audio files .aac, .aif, .aifc, .aiff, .au, .flac, .m4a, .m4b, .m4p, .m4r, .mid, .mp3, .oga, .ogg, .opus, .ra, .ram, .spx, .wav, .wma
    • eBooks .acsm, .aeh, .azw, .cb7, .cba, .cbr, .cbt, .cbz, .ceb, .chm, .epub, .fb2, .ibooks, .kf8, .lit, .lrf, .lrx, .mobi, .opf, .oxps, .pdf, .pdg, .prc, .tebr, .tr2, .tr3, .xeb, .xps
See this site: https://www.dropbox.com/developers/reference/devguide#app-permissions
 

GMan

Well-Known Member
Licensed User
Longtime User
Thx Mahares - as i mentioned.
When sending files to DropBox i ALWAYS .zip them before, so i never have had this case
 

peggjones

Active Member
Licensed User
Longtime User
This is all quite strange. I tried to upload with a different name and it made no difference.

However I have definitely successfully uploaded .db files in the past, they are still there on Dropbox now.

What I have now noticed is that although a newly uploaded .db file has %20 added to its name and cannot be opened from Dropbox, if I download it to my tablet the 20% is dropped from the name and I can open it from there with no problem.

This is all I need personally.

Thanks for the input from everyone.
 

gz7tnn

Member
Licensed User
Longtime User
"Which version of Dropbox SDK have you downloaded? This wrapper works with v2.x: https://www.dropbox.com/developers/sync/sdks/android"

Just when I want to try DropBox the only SDK version at dropbox.com/developers/sync/sdks/android becomes Version 3.0.0, updated June 9, 2014.
I have looked around but am unable to find any link to any V2.x - does anyone have a link?
 

gz7tnn

Member
Licensed User
Longtime User
Erel

Brilliant - thanks for the quick solution to that. Works, as in my quick test app prompted dropbox to give permissions.
Now to integrate that into another one...

Being new to this... it leads me now to a question around the App Key and App Secret values. I have created these on the dropbox site against an app name (eg myDropBoxApp) and created my test app under the same name. If I want to distribute this myDropBoxApp to a wider audience, are those the same Key/Secret values that I need to add to that app? or to put it another way will those values work for anyone that I distribute the app to?.

Great work.
 

GMan

Well-Known Member
Licensed User
Longtime User
What -besides the bug for which we need a additional xml-file- else is the BIG NEW in Version 3.0 (should be complete new 'cause the y change directly from 2 to 3) ?
MUST we use the 3.0 from mow on or can we still use 2. - or is there a deadline ?
 

Steini1980

Active Member
Licensed User
Longtime User
Hi, I implemented Lib for development a few month ago and tested successfully.
Today I tried again, click manager.link account doesn't raises the sub Manager_AccountReady

Now I tried to solve by updating from V1.25 to V3.00
I can Compile the Project but if try to start my application I get the following error:

Parsing Error
Fehler beim Parsen des Pakets

Did I have to change anything else after Updating to V3.00?
 

GMan

Well-Known Member
Licensed User
Longtime User
Mine are still working @ 2
 

Steini1980

Active Member
Licensed User
Longtime User
Sometimes it starts my application, but I get the following error if I try to open the DropBox activity:

B4X:
Installing file.
PackageAdded: package:de.dms.test
** Activity (main) Create, isFirst = true **
** Activity (main) Resume **
** Activity (main) Pause, UserClosed = false **
** Activity (datainterchange) Create, isFirst = true **
datainterchange_activity_create (B4A line: 39)
manager.Initialize(DropBoxAppKey, DropBoxAppSecret, "manager")
java.lang.NoSuchMethodError: no static method with name='reportCrash' signature='()V' in class Lcom/dropbox/sync/android/NativeLib;
    at com.dropbox.sync.android.NativeLib.nativeClassInit(Native Method)
    at com.dropbox.sync.android.NativeLib.<clinit>(NativeLib.java:27)
    at com.dropbox.sync.android.CoreAccountManager.initNativeLib(CoreAccountManager.java:155)
    at com.dropbox.sync.android.CoreAccountManager.<init>(CoreAccountManager.java:126)
    at com.dropbox.sync.android.DbxAccountManager.getInstance(DbxAccountManager.java:150)
    at com.dropbox.sync.android.DbxAccountManager.getInstance(DbxAccountManager.java:116)
    at anywheresoftware.b4a.dropbox.DbxAccountManagerWrapper.Initialize(DbxAccountManagerWrapper.java:53)
    at de.dms.poellath.datainterchange._activity_create(datainterchange.java:344)
    at java.lang.reflect.Method.invokeNative(Native Method)
    at java.lang.reflect.Method.invoke(Method.java:525)
    at anywheresoftware.b4a.BA.raiseEvent2(BA.java:170)
    at de.dms.poellath.datainterchange.afterFirstLayout(datainterchange.java:98)
    at de.dms.poellath.datainterchange.access$100(datainterchange.java:16)
    at de.dms.poellath.datainterchange$WaitForLayout.run(datainterchange.java:76)
    at android.os.Handler.handleCallback(Handler.java:730)
    at android.os.Handler.dispatchMessage(Handler.java:92)
    at android.os.Looper.loop(Looper.java:137)
    at android.app.ActivityThread.main(ActivityThread.java:5414)
    at java.lang.reflect.Method.invokeNative(Native Method)
    at java.lang.reflect.Method.invoke(Method.java:525)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1187)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1003)
    at dalvik.system.NativeStart.main(Native Method)

Furthermore I can't get the file "value/string.xml" readonly permissions, it's on our companies fileserver, I didn't have permissions to change the permisssions. After compiling the files will be deleted.

EDIT 15.40:
If I got read only permissions on domain level for the files I get an error while compiling.

Der Zugriff auf den Pfad "G:\DATEN\...\Software\Objects\res\values\strings.xml" wurde verweigert.
 
Last edited:

GMan

Well-Known Member
Licensed User
Longtime User
Didnt you have to use de.dms.test instead of MDE ?
 

GMan

Well-Known Member
Licensed User
Longtime User
Sorry. read it not well - without permissions on the server it couldnt work
 

Steini1980

Active Member
Licensed User
Longtime User
Problem is:
If it has READONLY Permission on Server (as described on this Thred), the compiler says Access Denied.
If the File has READ&WRITE Permission, the Compiler deletes the File and Directory values\strings.xml.
How can I compile and keep this data?
 

Steini1980

Active Member
Licensed User
Longtime User
I'm actually working with B4A 3.00, now I have seem that the newest release ist V3.80.
Could this solved in actual Release V3.80?
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…