ios - Colour of a substring in a string of text view -


i have text view like:

    uitextview statictxt = [[uitextview alloc]initwithframe:cgrectmake(10, 80, 300, 400)];         statictxt.backgroundcolor = [uicolor clearcolor];         statictxt.text = @"this textview";         statictxt.textcolor = [uicolor whitecolor]; [self.view addsubview:statictxt]; 

now want text "textview" should in different colour. how can this? thanks!!

you need create attributed text string, described in answer:

underline text in uitextview


Popular posts from this blog

How to calculate SNR of signals in MATLAB? -

c# - Attempting to upload to FTP: System.Net.WebException: System error -

ios - UISlider customization: how to properly add shadow to custom knob image -