38
Possible Duplicate:
How to convert from int to string in objective c: example codeā¦
How to convert integer to string in Objective C?
Possible Duplicate:
How to convert from int to string in objective c: example codeā¦
How to convert integer to string in Objective C?
If you really want to use String:
NSString *number = [[NSString alloc] initWithFormat:@"%d", 123];
But I would recommend using NSNumber:
NSNumber *number = [[NSNumber alloc] initWithInt:123];
Then just add it to the array.
[array addObject:number];
Don't forget to release it after that, since you created it above.
[number release];