Search code examples
iphoneobjective-cuilabel

Allow user to select text from UILabel to copy


I have a UILabel, but how can I allow the user to select a portion of it's text. I don't want the user to be able to edit the text nor the label/textfield to have a border.


Solution

  • It is not possible with UILabel.

    You should use UITextView for that. Just disable editing using textFieldShouldBeginEditing delegate method.