dropbox

Dropbox Sync API Android - Updating Cached Files

十年热恋 提交于 2019-12-01 12:06:56
I am facing trouble in updating the existing cached file within my Android Application. for(DbxFileInfo fInfo : fileList) { Log.d(TAG, "File Path = "+fInfo.path.toString()); String fileName = fInfo.path.getName().trim(); try { DbxPath tempFilePath = new DbxPath(fInfo.path.toString()); DbxFile tempFile = mDbFileSystem.open(tempFilePath); if(tempFile.getSyncStatus().isCached) { Log.v(TAG, "File is already cached !"); if(tempFile.getSyncStatus().isLatest) { Log.v(TAG, "File's Latest Version is Cached !"); } else { Log.v(TAG, "File's Latest Version is not Cached !"); } } try { tempFile

Android - Choose Image from Gallery and store it in a File type variable

核能气质少年 提交于 2019-12-01 11:17:36
I am a new to Android Development. I wish to select an image or a video from the Gallery of an Android Device. Store it in a variable of type File . I am doing this, since I need to upload the image/video on dropbox using the Android API from my application. The constructor takes in the fourth parameter of the type File . I am not sure, what to pass as a file since all the examples I searched display the image chosen in an ImageView by using the url and making a bitmap. imageView.setImageBitmap(BitmapFactory.decodeFile(picturePath)); Here is the code, I have. final Intent galleryIntent = new

How do I authenticate in DropboxAPI v2 for Android?

前提是你 提交于 2019-12-01 10:52:32
问题 I've just started out and I'm following this tutorial https://www.dropbox.com/developers/documentation/java#tutorial But there's no login. Nothing asks you for a username, password. That means I can't actually get a GUI that every app with "Share to Dropbox" option has. Am I stuck with one account? Do I have to find a way to get a person's ACCESS_TOKEN or is there a more elegant GUI solution out there(like with Google Drive and their intentsenders)? 回答1: To use the Dropbox API v2 in Android,

Dropbox Sync API Android - Updating Cached Files

折月煮酒 提交于 2019-12-01 10:41:08
问题 I am facing trouble in updating the existing cached file within my Android Application. for(DbxFileInfo fInfo : fileList) { Log.d(TAG, "File Path = "+fInfo.path.toString()); String fileName = fInfo.path.getName().trim(); try { DbxPath tempFilePath = new DbxPath(fInfo.path.toString()); DbxFile tempFile = mDbFileSystem.open(tempFilePath); if(tempFile.getSyncStatus().isCached) { Log.v(TAG, "File is already cached !"); if(tempFile.getSyncStatus().isLatest) { Log.v(TAG, "File's Latest Version is

Android - Choose Image from Gallery and store it in a File type variable

空扰寡人 提交于 2019-12-01 09:55:39
问题 I am a new to Android Development. I wish to select an image or a video from the Gallery of an Android Device. Store it in a variable of type File . I am doing this, since I need to upload the image/video on dropbox using the Android API from my application. The constructor takes in the fourth parameter of the type File . I am not sure, what to pass as a file since all the examples I searched display the image chosen in an ImageView by using the url and making a bitmap. imageView

open iBooks from my app

非 Y 不嫁゛ 提交于 2019-12-01 09:22:50
I have some PDF in my app. I want to provide an option to open those PDF in other third party e-readers app that might be installed on the device, like Stanza and iBooks. Dropbox application has successfully implemented this feature and I can't find any information on how to detect what other e-readers are available on the device or what the custom url scheme is for those apps. Any help would be greatly appreciated. thanks in advance guys. Check this out! http://developer.apple.com/iphone/library/documentation/UIKit/Reference/UIDocumentInteractionController_class/Reference/Reference.html#/

open iBooks from my app

扶醉桌前 提交于 2019-12-01 07:30:06
问题 I have some PDF in my app. I want to provide an option to open those PDF in other third party e-readers app that might be installed on the device, like Stanza and iBooks. Dropbox application has successfully implemented this feature and I can't find any information on how to detect what other e-readers are available on the device or what the custom url scheme is for those apps. Any help would be greatly appreciated. thanks in advance guys. 回答1: iBooks NSString *stringURL = @"itms-books:";

NSURLErrorDomain error -1021

梦想与她 提交于 2019-12-01 02:03:59
I'm developing an app were I integrated dropbox. Login is done properly also I'm able to create folder in dropBox. But when I try to load file I'm getting error Following error I'm getting error making request to /1/files_put/dropbox/Info.plist - Error Domain=NSURLErrorDomain Code=-1021 "The operation couldn’t be completed. (NSURLErrorDomain error -1021.)" UserInfo=0x6859bc0 {destinationPath=/Info.plist, sourcePath=/Users/bcod/Library/Application Support/iPhone Simulator/5.0/Applications/0E1EE43C-8F6B-40FA-8696-D3992DA2DCE5/DBRoulette.app/Info.plist} I'm not getting this error when I'm

File uploading Dropbox v2.0 API

狂风中的少年 提交于 2019-12-01 01:03:05
I'm using the new Dropbox SDK v2 for .NET. I'm trying to upload a document to a Dropbox account. public async Task UploadDoc() { using (var dbx = new DropboxClient("XXXXXXXXXX")) { var full = await dbx.Users.GetCurrentAccountAsync(); await Upload(dbx, @"/MyApp/test", "test.txt","Testing!"); } } async Task Upload(DropboxClient dbx, string folder, string file, string content) { using (var mem = new MemoryStream(Encoding.UTF8.GetBytes(content))) { var updated = await dbx.Files.UploadAsync( folder + "/" + file, WriteMode.Overwrite.Instance, body: mem); Console.WriteLine("Saved {0}/{1} rev {2}",

Using saved Dropbox authentication details on Android

折月煮酒 提交于 2019-11-30 22:03:42
In the Getting started article on Dropbox website they have a tutorial how to use Core API with Android to get started. When the application launches for the first time, the user is asked to authenticate the software to use the users Dropbox account. After the authentication is successfully finished, you'll receive a pair of authentication strings, the key and a secret. After the user has authenticated the application to use his or her Dropbox account I save the key and the secred using Android's SharedPreferences. How do I use these saved values? I don't mean how I retrieve them using