1

I am developing a Windows Form application in C#. I have a form with RichTextBox which shows the data. The data comprises of Contents and the relevant information for each topic under Contents.

How do I make the content's data as links that scroll to a specific section upon clicking?

Code Maverick
  • 20,171
  • 12
  • 62
  • 114
shashi3089
  • 11
  • 1
  • 3
    What about a WebBrowser control and HTML instead? – Alan Mar 14 '14 at 16:27
  • 1
    The RichTextBox displays whatever you pass to it. If you want some text to be a link, you have create the proper RTF text. Check [this question](http://stackoverflow.com/questions/2850575/what-is-the-rtf-syntax-for-a-hyperlink) on how to do it. I suspect what you really want though is to add a Table of Contents. I'm not sure if RichTextBox supports it though. Third-party controls do – Panagiotis Kanavos Mar 14 '14 at 16:33
  • Do you have any examples of the actual data? Is it XML, JSON, some other format? – Piotr Justyna Mar 14 '14 at 16:33
  • @PiotrJustyna a RichTextBox displays either plain text or RTF – Panagiotis Kanavos Mar 14 '14 at 16:36
  • @PanagiotisKanavos Well, at this stage we don't know what the data actually is and how it is translated into text. We can safely assume it's anything. Even XML or JSON presented as plain text. – Piotr Justyna Mar 14 '14 at 16:39

0 Answers0