1
我知道如何創建一個目錄,如:如何使用objective-c在Dropbox API中的目錄中創建目錄?
[[self restClient] createFolder: folderName];
但如果我要創建文件夾「B」文件夾裏面「A」,會怎麼做呢?
目錄層次是: A> B> c.txt
我可以創建 「A」,但我無法裏面A.
任何幫助,將不勝感激創造B中。
我知道如何創建一個目錄,如:如何使用objective-c在Dropbox API中的目錄中創建目錄?
[[self restClient] createFolder: folderName];
但如果我要創建文件夾「B」文件夾裏面「A」,會怎麼做呢?
目錄層次是: A> B> c.txt
我可以創建 「A」,但我無法裏面A.
任何幫助,將不勝感激創造B中。
你是成功的一半,就試試這個
[[self restClient] createFolder:@"A"];
然後
[[self restClient] createFolder:@"A/B"];
- (void)restClient:(DBRestClient*)client createdFolder:(DBMetadata*)folder{
NSLog(@"Meta Data Path %@",[folder path]);
NSLog(@"Meta Data Filename %@",[folder filename]);
NSLog(@"Meta has directory %d",[folder isDirectory]);
}
// Folder is the metadata for the newly created folder
- (void)restClient:(DBRestClient*)client createFolderFailedWithError:(NSError*)error{
NSLog(@"Fail Error %@",error);
}
// [error userInfo] contains the root and path
可以請你說,如果它不工作了! – Bala 2012-08-04 12:19:02
謝謝!它確實有效。 – user1528958 2012-12-05 16:36:43
如果它是正確的,你可以勾選它。 ;) – Bala 2012-12-05 17:24:31