I have a UITableView. In row I need to setup text, so I need to use UILabel or UITextView. I need to detect phone number in text, so I use UITextView. BUT I need to set text only in 2 lines and if it’s longer, setup ellipses in the end , because row height isn’t big, so that work UILabel do perfect. So how to be ??? Can UILabel detect phone number ? or can i set UITextView in 2 lines and set ellipses in the end ?? Thanks…
I have a UITableView . In row I need to setup text, so I
Share
I do not think that the UITextView has a property that let you set ellipses at the end if the text is to long. However that is simple to fix:
NSString documentation
You could use this method if all you want to do is to allow let say 120 characters, and starting from 0.
Maybe you should use a mutable string for this, I do not know what performes the best. But if you do this, you could atleast detect phone numbers.