views:

254

answers:

1

Hi, maybe it is just to late or I´m to stupid, but I can´t solve this problem.

I use this code to file the rows in my UIPickerView:

self.component1Data = [NSArray arrayWithObjects: @"Sample", @"Sample1", @"...", nil];

How can I get a NSString instead of the "sample"? I tried it with "%@" but it doesn't work:

self.component1Data = [NSArray arrayWithObjects: @"%@",string, @"%@",string2, @"...", nil];
+9  A: 
self.component1Data = [NSArray arrayWithObjects: string, string2, nil];

Assuming string and string2 are of type NSString *.

bbum
Haha, great :)It is to late.
Flocked