Forum guidelines
  • Home
  • »
  • C# Language
  • »
  • How to make a word in a text modifiable(Change color, ....)
AuthorQuestion
How to make a word in a text modifiable(Change color, ....)
Posted By Mr Celetron on 27 Jun 2012
I have a problem, i have text stored in xml file formatting like this:


    <sentence>
            <token tag='man'>
                    John
            </token>
            <token>
                    is
            </token>
            <token>
                    a doctor
            </token>
    </sentence>
    <sentence>
            <token tag='man'>
                    He
            </token>
            <token>
                    has
            </token>
            <token>
                    a wife
            </token>
    </sentence>
    ....


I want to show this text for User(on a TextBox, a Panel,...) ,and tokens which have tag='man'(in this case:John,He ) have different color from the rest ,plus, they can be Clicked (to show extra information,etc) .It appears that in ToolBox there is not such a tool could do this .So I don't know how to solve it, does anybody have any suggestions ??Thanks for reading this! 
 

AuthorReply
Re: How to make a word in a text modifiable(Change color, ....)
Posted By Vulpes on 27 Jun 2012  
Spire.Doc

SPONSORED BY

Spire.Doc - Free .NET Word API
Use Spire.Doc to create, read, write, print, and convert word documents to OpenXML, RTF, TXT, XPS, EPUB, EMF, HTML, Image and PDF.