In this article you will learn how to create a RichTextBox in C#.
Here's an article on how we can create a Textbox where one can write “text” into the Textbox and then apply various “effects” on that particular “text”. So let’s get started I have mentioned the Step s to guide how to do this activity. Step 1: Open visual studio 2010 or any version you have. Step 2: Click on the file tab, then new and project. Under installed templates select C#, then windows and ”Windows Form Application”. Step 3: Once all the formalities of providing the proper name to the project and providing the path is finished you will be redirected to one default “form”. Step 4: All you need to do is simply drag one RichTextbox from the toolbox and 7 buttons. Step 5: Now you can go to the properties window by right clicking each control and change some of the properties as per your requirement. Step 6: Once creating the user interface part is over simply double click on buttons to generate the click event and then write the codes as in the following: Step 7: Once you write all these codes in there particular events handlers, simply run your project and check everything is working fine. Step 8: Congrats you have now made one project, Output:
Printing in C# Made Easy