I have a Property list = DictionaryofAddresses, inside which is an NSDictionary StoredAddr;
The keys inside StoredAddr are Mac Addresses, and the values an array of RSI readings.
I have an array, compareAddr (which holds an array of Mac addresses)
I want to use a loop, in which the value at compareaddr[i] will be used as a key, to match whether addresses in my array match any keys in my dictionary.
NSArray *compareAddr = [DiscoveredAP allKeys];
for (int i = 0; i < [compareAddr count]; i++){
NSArray *RSIatAddr = [[dictionaryOfAddresses objectForKey:@"StoredAddr"]objectForKey:compareAddr[i]];
The following code gives me an error :
expected identifier
Thank you for any help
Use
[compareAddr objectAtIndex:i]instead ofcompareAddr[i]