I want to replace the text in the text of a UITextView in the selected range. This is my question. Here I mention what I did? and what do I want to do ?. I have a UITextView and the text entered below in a textview.
Ask question here, I saved a range of text in text form. The range of text is {17, 0}. I take NSRange in the delegate -(void) textViewDidChange:(UITextView *)textView.
Now I want to replace the text questionwith answer, and I want to replace the text herewith them. The UITextView.text look like this,Ask answer them "after replacing the texts.
How to replace texts with selected ranges? could you help me? Thanks in advance.
source
share