NSString problem on iphone while displaying on UILabel

Posted by prajakta on Stack Overflow See other posts from Stack Overflow or by prajakta
Published on 2011-01-12T01:36:06Z Indexed on 2011/01/12 1:53 UTC
Read the original article Hit count: 503

Filed under:

i have a issue , i am asking as new question as previoes one was messed

NSString *s=@"hi\nhello\n\nwelcome to this world\ni m jhon"
label.frame = ...//big enough height
label.numberOfLines = 0;
label.text = s;

this code helps me to separate string based on \n

but if i do this

NSString *s=Ad.content //where Ad.content value is **hi\nhello\n\nwelcome to this world\ni m jhon**


label.numberOfLines = 0;
label.text = s;

i am not able to sperate them by \n , what i am doing wrong here kindly suggest

Thanks

© Stack Overflow or respective owner

Related posts about iphone