I have a NSMutableArray that is set based on selections the user makes. I am than trying to pass that to a NSDictionary that is set to my parameter to be sent to my server. I want to than grab those values placed inside the parameters.
Heres what I am doing:
NSMutableArray: is being set by the following: [_selectedCells addObject:label.text];
NSDictionary *dictionary = @{ @"title": _titlefor.text,
@"description": _description.text,
@"time_limit": _timeLimit.date, @"toWho": @""};
toWho is where I want to send the values the user selected.
I've tried something like,[dictionary setValue:self.viewControllers.selectedCells forKey:@"toWho"]; But this does not work correctly.
I think I will have to use a NSMutableDictionary but can I send this to parameters to be sent to my server?
Heres how I am adding parameters:
NSMutableURLRequest *request = [httpClient multipartFormRequestWithMethod:@"POST" path:@"downloadFileChallange.php" parameters:dictionary constructingBodyWithBlock:^(id <AFMultipartFormData>formData)
{
[formData appendPartWithFileData:webData name:@"file" fileName:newUsername mimeType:@"video/quicktime" ];
}];
Suggestions, thoughts?
NSMutableURLRequestbefore, so I don't know if just setting theparametersparameter to the dictionary will work. Sorry!_descriptionand_timeLimitinstead ofself.descriptionandself.timeLimit? It's wrong.