I am creating a windows phone 8.1 app where app provides the user with a text box. I want to highlight all the hashtags used in the textbox with different color. So as soon as user presses hash(#) on the screen, font color will change till user presses a space key. For example, user enters:
This is a #sample statement.
Font color remains black for the part of text "This is a", but as soon as user presses # key, color changes to red (including the hash itself) and all subsequent characters are in red colored font. So #sample appears in read color. Once user presses a space after the word sample, font color changes back to black and all the remaining text appears to be in black color. How can I achieve this? I tried changing the font color but then it changes for the entire text and not just for the hashtag.