Tutorial by Examples: dropbox

This example uses the Dropbox .NET library to get a shared link for a file, either by creating a new one, or retrieving an existing one: SharedLinkMetadata sharedLinkMetadata; try { sharedLinkMetadata = await this.client.Sharing.CreateSharedLinkWithSettingsAsync (path); } catch (ApiException...
This uses the SwiftyDropbox library to upload a file from a NSFileHandle to the Dropbox account using upload sessions, handling every error case: import UIKit import SwiftyDropbox class ViewController: UIViewController { // filled in later in doUpload: var fileHandle : NSFileHandle?...
This uses the Dropbox Java SDK to download a file from the Dropbox API at the remote path /Homework/math/Prime_Numbers.txt to the local file Prime_Numbers.txt: String localPath = "Prime_Numbers.txt"; OutputStream outputStream = new FileOutputStream(localPath); FileMetadata metadata = cl...
This uses the Dropbox Java SDK to share a file at "/test.txt" with a specific user: List<MemberSelector> newMembers = new ArrayList<MemberSelector>(); MemberSelector newMember = MemberSelector.email("<EMAIL_ADDRESS_TO_INVITE>"); newMembers.add(newMember); ...
This uses the Dropbox Java SDK to retrieve an existing shared link for /Testing/test.txt specifically: ListSharedLinksResult listSharedLinksResult = client.sharing() .listSharedLinksBuilder() .withPath("/Testing/test.txt").withDirectOnly(true) .start(); System....
This uses the Dropbox Objective-C SDK to upload a local file to Dropbox as "/test.txt". [[client.filesRoutes uploadUrl:@"/test.txt" inputUrl:[NSURL fileURLWithPath:@"/local/path/to/test.txt"]] response:^(DBFILESFileMetadata *metadata, DBFILESUploadError *uploadError, D...
This uses the Dropbox Objective-C SDK to get the user's account information from the Dropbox API. [[client.usersRoutes getCurrentAccount] response:^(DBUSERSFullAccount *account, DBNilObject *_, DBRequestError *error) { if (account) { NSLog(@"%@", account); } else if (er...
This uses the Dropbox Objective-C SDK to download a file from Dropbox at "/test.txt". [[[client.filesRoutes downloadData:@"/test.txt"] response:^(DBFILESFileMetadata *metadata, DBFILESDownloadError *downloadError, DBRequestError *error, NSData *fileData) { if (metadata) { ...

Page 2 of 2