Home
Search
 
What's New
Index
Books
Links
Q & A
Newsletter
Banners
 
Feedback
Tip Jar
 
C# Helper...
 
XML RSS Feed
Follow VBHelper on Twitter
 
 
 
MSDN Visual Basic Community
 
 
 
 
 
TitleColor HTML tags in a RichTextBox
DescriptionThis example shows how to color HTML tags in a RichTextBox in Visual Basic 6. It searches the text for tags in brackets and colors them appropriately. It continuously rechecks the text using a timer so it can color tags as you type.
KeywordsRichTextBox, Rich Text, RTF, HTML, color tags, tag
CategoriesControls, Utilities
 
Thanks to Yaron Budowski.

When a timer fires, the program searches the text for open brackets (<) and their corresponding close brackets (>). It colors various components of the HTML text in different ways. The timer makes the program recheck the code periodically so it colors tags as you type. It saves time by only recoloring the line you are typing on rather than the whole file.

See the code for the details.

 
 
Copyright © 1997-2010 Rocky Mountain Computer Consulting, Inc.   All rights reserved.
  Updated