1
我有一个文本标签,当我按下按钮时会发生变化,标签确实会随着使用数组而改变,而不是数组的值我得到数组的键。如何获取文本标签中的数组值而不是密钥
我应该怎么做才能获得这些值?
这是代码:
NSString*path = [[NSBundle mainBundle]pathForResource:@"words" ofType:@"plist"];
words = [[NSMutableArray alloc]initWithContentsOfFile:path];
NSString*generateRandomLabel =[NSString stringWithFormat:@"%d", arc4random_uniform([ words count])];
[self.randomLabel setText:generateRandomLabel];
嗯,等...有一个数组没有钥匙...或者你在PHP编写你的iOS应用? – 2012-12-05 14:55:21