The following code runs, but it only returns the same string, as many counts as the array. I want to return all the objects in the array (values) to the "lblMessage", one by one. Where is my mistake?

int i;
	int count;
	for (i=0, count = [values count]; i<count; i=i+1) 
		self.lblMessage.text = [NSString stringWithFormat:@"%@\n%@", self.lblMessage.text, [values objectAtIndex:[values count]-1]];
	[values release];
}

That's the strangest C code I've ever seen.

Hey, what is that ???:|
I think not C language.....may be D, E or F...

No, seriously !!! what is that ????:confused:

Hi,
Where you find this code.This is C language code!!!!!!!!!!!!!!!!!!!!You can suggestion me where we find this....................

It's Objective-C, not C, and there is an extremely big difference between the two. Post it somewhere else, to a Mac/iPhone-related development forum, like MacRumors or the programming-oriented StackOverflow.

All of you have so much to say if it is C or not C completely ignoring thread title.

@AD, thanx for flagging post

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.