We’re Still Here to Help (Even Over the Holidays!) - find out more here.
Forum Discussion
cris3c
6 years agoExplorer | Level 4
Reading content from a file and show it WITHOUT downloading
hi all,
Currently I am developing an Android App with Android Studio and I got Dropbox API to get information from Dropbox. I am blocked with a method to get information from Dopbox account (.t...
Greg-DB
Dropbox Community Moderator
6 years agoTechnically you don't need to build from source if you don't need to change the source code for the SDK (which you probably don't have reason to do). Instead, it's much easier to just install a released version. For example, you can replace this line from the Android example build.gradle:
implementation group: 'com.dropbox.core', name: 'dropbox-core-sdk', version: '0-SNAPSHOT', changing: true
With this instead:
implementation 'com.dropbox.core:dropbox-core-sdk:3.1.5'
Then once you do a Gradle sync for that change in Android Studio, it will download and install it for you.
cris3c
6 years agoExplorer | Level 4
Hi,
The code lines you told me work perfectly but I found another error. I think android studio does not find the executable run.exe. I attach the following terminal message. It is in spanish but it can be read easily.
Could you help me out, please?
- Greg-DB6 years ago
Dropbox Community Moderator
I see you're now attempting to run the "authorize" example, and are trying to do so via a "run" command. That's actually referring to this "run" file which is a bash script, so you'd need to be running in an environment that can run bash scripts (such as cygwin).
If you're just trying to build an Android app though, I recommend just referring to the Android example app. The "authorize" example is just a command line app.
- cris3c6 years agoExplorer | Level 4
Hi, I was trying to run the example in an environment that does not support bash scripts. So as you said, I built the android example, but when I try to run it this error comes:
- API 'variant.getMappingFile()' is obsolete and has been replaced with 'variant.getMappingFileProvider()'.
- API 'variantOutput.getPackageApplication()' is obsolete and has been replaced with 'variant.getPackageApplicationProvider()'.
- src/main/java/com/dropbox/core/examples/android/DownloadFileTask.java
- package com.dropbox.core.v2.files does not exist
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot access DbxClientV2Base class file for com.dropbox.core.v2.DbxClientV2Base not found
- src/main/java/com/dropbox/core/examples/android/FilesActivity.java
- package com.dropbox.core.v2.files does not exist
- package com.dropbox.core.v2.files does not exist
- package com.dropbox.core.v2.files does not exist
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class FolderMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class ListFolderResult
- cannot find symbol class FileMetadata
- uses or overrides a deprecated API.
- src/main/java/com/dropbox/core/examples/android/FilesAdapter.java
- package com.dropbox.core.v2.files does not exist
- package com.dropbox.core.v2.files does not exist
- package com.dropbox.core.v2.files does not exist
- cannot find symbol class Metadata
- cannot find symbol class Metadata
- cannot find symbol class Metadata
- cannot find symbol class Metadata
- cannot find symbol class FolderMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class FolderMetadata
- cannot find symbol class FolderMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class FolderMetadata
- src/main/java/com/dropbox/core/examples/android/FileThumbnailRequestHandler.java
- package com.dropbox.core.v2.files does not exist
- package com.dropbox.core.v2.files does not exist
- package com.dropbox.core.v2.files does not exist
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot find symbol variable ThumbnailSize
- cannot find symbol variable ThumbnailFormat
- cannot find symbol method files()
- src/main/java/com/dropbox/core/examples/android/GetCurrentAccountTask.java
- package com.dropbox.core.v2.users does not exist
- cannot find symbol class FullAccount
- cannot find symbol class FullAccount
- cannot find symbol class FullAccount
- cannot find symbol class FullAccount
- cannot find symbol method users()
- src/main/java/com/dropbox/core/examples/android/ListFolderTask.java
- package com.dropbox.core.v2.files does not exist
- cannot find symbol class ListFolderResult
- cannot find symbol class ListFolderResult
- cannot find symbol class ListFolderResult
- cannot find symbol class ListFolderResult
- cannot find symbol method files()
- src/main/java/com/dropbox/core/examples/android/UploadFileTask.java
- package com.dropbox.core.v2.files does not exist
- package com.dropbox.core.v2.files does not exist
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot find symbol class FileMetadata
- cannot find symbol variable WriteMode
- cannot find symbol method files()
- src/main/java/com/dropbox/core/examples/android/UserActivity.java
- package com.dropbox.core.v2.users does not exist
- cannot find symbol class FullAccount
I think the error is in the packages. Could you please help me out?
- Greg-DB6 years ago
Dropbox Community Moderator
This appears to indicate that the Dropbox library wasn't successfully loaded. Were you able to add it as instructed in my earlier comment? Did the Gradle sync complete successfully after that?
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!