Note that there are some explanatory texts on larger screens.

plurals
  1. POuploadedFile not called
    primarykey
    data
    text
    <p>I have an app where I upload a simple .csv file to Dropbox. The files upload perfectly when I send them, but the restClient uploadedFile method is not called. I would like this to use this to display to the user that the file has been uploaded successfully. I seem to remeber it was called the first few times I ran the code, but then it stopped and I can't see why.</p> <p>Here are some snippets:</p> <pre><code>- (void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex { if (buttonIndex == 0) //Cancel { } else if (buttonIndex == 1) //Send { NSString *docPath = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) objectAtIndex:0]; NSString *CCD = [docPath stringByAppendingPathComponent:@"CCD.csv"]; if ([[NSFileManager defaultManager] fileExistsAtPath:CCD]) { NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; NSString *machineName = [defaults objectForKey:@"machineName"]; NSString *fileTitle = [defaults stringForKey:@"setTitle"]; NSMutableString *filePath = [NSMutableString string]; [filePath appendString:docPath]; [filePath appendString:@"/CCD.csv"]; NSString *destDir = @"/"; [SVProgressHUD showWithStatus:[NSString stringWithFormat:@"Sending to %@...", machineName]]; [[self restClient] uploadFile:fileTitle toPath:destDir withParentRev:nil fromPath:filePath]; } } } - (void)restClient:(DBRestClient*)restClient uploadedFile:(NSString*)filePath { NSLog(@"File uploaded successfully"); [SVProgressHUD dismiss]; }; </code></pre> <p>As I said, it uploads the file perfectly, I just don't get the call to the uploadedFile method.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload