English 中文(简体)
如何在伐木后展示Droop Box Folders
原标题:How to display Dropbox Folders after logging in

I am in the process of learning the Dropbox SDK. I want to learn how to display the users Dropbox folders as well as give the user the option to upload the file from my app to their Dropbox account.

我从他们的榜样来看,但没有给我必要的信息。

谁能帮助我?

问题回答

I think you might find this tutorial useful. http://www.nanaimostudio.com/blog/2011/1/20/how-to-synchronize-your-app-data-using-dropbox-api.html

You can call upload method on the DBRestClient object.

    NSString* path = [self getDocumentPath];//or however you can obtain the path where your file is stored
   [restClientObject uploadFile:@"filename" toPath:@"/" fromPath:path]; 
   //you can choose to upload to the dropbox root directory(above) or a folder of your choice eg toPath:@"/myfolder"

Use loadMetaData for displaying the contents of dropbox folder

 [restClientObject loadMetadata:@""];

you also have to implement loadedMetadatafunction. Refer the tutorial above.

-(void)restClient:(DBRestClient *)client loadedMetadata:(DBMetadata *)metadata{

    NSMutableArray *list=[[NSMutableArray alloc] init];
    for (DBMetadata *child in metadata.contents) {
        [list addObject:child];
    }
    self.arrayFoldersList=[[NSMutableArray alloc] initWithArray:list];
    [self.tableView reloadData];

}
    [self.restClient loadMetadata:@""];

我认为,这将帮助你。





相关问题
C# Networking API s [closed]

Lately I ve been looking for a good networking API i could possibly use and/or reference some of the code within, but i have mere luck searching for some on Google/Bing. Hopefully somebody here has ...

getting XML from other domain using ASP.NET

I m fairly new to ASP.NET. And I was wondering how I could go about getting xml from a site (Kuler s API in this case), and then post the result using AJAX? So what I want here, is to be able to do a ...

Most appropriate API for URL shortening service

I ve just finished an online service for shortening URLs (in php5 with Zend Framework); you can enter an URL and you get an short URL (like tinyurl and such sites). I m thinking about the API for ...

UML Diagram to Model API

I need to create a diagram to document a RESTFul API that build, which UML diagram should I use? Thanks in advance,

How best to expose Rails methods via an API?

Let s say I have a model foo, and my model has a publish! method that changes a few properties on that model and potentially a few others too. Now, the Rails way suggests that I expose my model over ...

简讯

我是否可以使用某些软件来建立简便的航天国家服务器,最好是在 Java? 所有我都希望我的航天国家服务机在任何要求中都用同样的IP地址来回答。

About paypal express checkout api

In this picture,there are 3 main steps:SetExpressCheckout,GetExpressCheckoutDetails and DoExpressCheckoutDetails,I m now sure SetExpressCheckout is to be called by myself,what about ...