views:

26

answers:

2

Hi friends,

I am trying to put NSArray data by([array valueForKey:@"value_name"]) in uilabel it throws exception.

Regards, sathish

A: 

How are you assigning this to the UILabel?

You should be doing something like:

myLabel.text = [myArray objectAtIndex:0];

If you want to retrieve it using the valueForKey method then a variable type such as NSDictionary maybe a better match for it...

James Raybould
A: 

Hi james

myLabel.text = [myArray valueForKey:@"my_value_name"];

If NSDictionary can you provide with me some codes.

Regards, sathish

sathish