views:

55

answers:

2

I have an array of unichars i need to convert it to nsstring. How can i do this?

+4  A: 

NSString has a method for that:

+ (id)stringWithCharacters:(const unichar *)chars length:(NSUInteger)length

robinjam
Oh, I think this is better than mine
vodkhang
@vodkhang: it is, yours will fail since the unichar is 16-bits wide
Jason Coco
A: 

Have you tried reading the "NSString Class Reference"?

Look at stringWithCharacters:length:

Frank C.