Changing the forecolor and backcolor of text in a textbox
问题 I'm making a C++ code editor application using VB.NET. I'd like to change the color of the keywords as the user types it. Also I'm looking for a way to highlight some lines of the code. Is there a way to change the forecolor and backcolour of a piece of text inside a textbox or a rich textbox? 回答1: I do not really know what you want to do so here are some options. If you want a step by step tutorial on how to write a syntax highlighting control, you can read these articles: Syntax