I'm trying to implement a UIProgressView for an image upload so I set it up with
uploadProgress = [[UIProgressView alloc] initWithProgressViewStyle:UIProgressViewStyleDefault];
[uploadProgress setFrame:CGRectMake(85, 19, 150, 9)];
imageRequest = [[ASIFormDataRequest alloc] initWithURL:[NSURL URLWithString:@"http://theurl.com"]];
[imageRequest setDelegate:self];
[imageRequest setDidFinishSelector:@selector(uploadedImage:)];
[imageRequest setDidFailSelector:@selector(asiRequestFailed:)];
[imageRequest setTimeOutSeconds:60];
[imageRequest addData:imgData forKey:@"file"];
[imageRequest addPostValue:[parameters yajl_JSONString] forKey:@"json"];
[imageRequest setUploadProgressDelegate:uploadProgress];
[imageRequest setShowAccurateProgress:YES];
[imageRequest startAsynchronous];
It loads for awhile, then jumps to almost 100% then it gets to 100%, then after a couple seconds, it completes. Is there something I'm missing in my code, or do I need to do something on the server side?
Thanks