我试图将文件上传到Dropbox。上传不起作用。上传方法如下。如何将文件上传到Dropbox ios
// RootViewController.m
-(NSString *)getDocumentPath{
NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
NSString *path = [[paths objectAtIndex:0]stringByAppendingPathComponent:FILENAME];
return path;
}
-(IBAction)download:(id)sender{
NSLog(@"download pressed");
[self.activityIndicator startAnimating];
[self.restClient loadFile:@"/dbTutorial.plist" intoPath:[self getDocumentPath]];
}
-(IBAction)upload:(id)sender{
NSLog(@"upload pressed");
[self.activityIndicator startAnimating];
NSString *path = [self getDocumentPath];
[self.itemArray writeToFile:path atomically:YES];
[self.itemArray uploadFile:FILENAME toPath:@"/" fromPath:path];// When I build this is the warning that I get:NSMutableArray may not respond to -uploadFiletoPath:fromPath
}
非常感谢。任何帮助将不胜感激。
能否请你告诉我,我怎么可以跟踪上传进度? (无效)restClient:(DBRestClient *)客户端uploadProgress:(CGFloat)进度 forFile:(NSString *)destPath from :(NSString *)srcPath; 但无法如何使用此... – Meet 2012-06-18 12:26:51