Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- NSMutableArray * objDateTimeValues = [[NSMutableArray alloc] initWithObjects:theDate, theTime, nil];
- NSDictionary * dictObjDateTime = [NSDictionary dictionaryWithObjects:objDateTimeValues forKeys:objDateTime];
- NSString * dateAndTime = [NSString stringWithFormat:@"%@, %@", [dictObjDateTime objectForKey:@"date"], [dictObjDateTime objectForKey:@"time"]];
- // Step 1.2 => Create a dictionary for the other values
- NSMutableArray * objJsonConfRecv = [[NSMutableArray alloc] initWithObjects:@"datetime", @"a", @"b", @"c", @"d", nil];
- NSMutableArray * objJsonConfRecvValues = [[NSMutableArray alloc] initWithObjects:dateAndTime, test1, test2, test3, test4, nil];
- NSDictionary * dictObjJsonConfRecv = [NSDictionary dictionaryWithObjects:objJsonConfRecvValues forKeys:objJsonConfRecv];
- if ([NSJSONSerialization isValidJSONObject:dictObjJsonConfRecv])
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement