Hello, why can´t I fill my NSArray? Where is my mistake? He always just fill one object/image to the nsarray. I set a NSlog to check which value string has and he shows me all the 20 urls.
for (int i = 0, count = [bild count]; i < count; i = i++) {
NSString * string = [bild objectAtIndex:i];
NSURL *url = [NSURL URLWithString:string];
NSData *datas = [NSData dataWithContentsOfURL:url];
UIImage *img = [[UIImage alloc] initWithData:datas];
myArray = [NSMutableArray array]; // this will autorelease, so if you need to keep it around, retain it
[myArray addObject:img];
int count = [myArray count];
NSLog(@"There are %d elements in my array", count);
}
Thanks for your help!