Click here to Skip to main content
14,447,769 members

RichTextBox user control for ASP.NET 1.1

Rate this:
4.92 (11 votes)
Please Sign up or sign in to vote.
4.92 (11 votes)
20 Sep 2007
RichTextBox user control for ASP.NET 1.1


I just finished creating a RichTextbox control for my website.

So I thought it will be a great idea to put it on CodeProject so that it can be used for other developers who want such control and also I can get some good feedback to create better controls and improving the current one.

This is a simple control that lets you put in text and you can make the entered text Bold, Underline , Italics, Align the text, put a horizontal rule, give it desired font and size.

Also I have made the code such that you can get the text easily from the control using the getText() and getHTML() methods. The getText() method will give the inner text of the textbox and the getHTML() method will give the text with the HTML code embedded in the resulting text.

Checkout the code of the control where I have given a working example of using it.

Also the control is such designed that it will work perfectly on a Datagrid. Where in you can use it as a template item.

Any comments and/or suggestion are very much appreciated.

Using the code

Using the code is pretty simple and easy. Any web developer who has littele knowledge of working with user controls will be able to use it.

Although i have given a fully functional working example with it. You can view the example and learn how to use the control.

Screen Shots

Screenshot - ScreenShot1.jpg

working example in a stand alone page.

Screenshot - ScreenShot2.jpg

working example in a grid.


In case anyone wants to add some more functionalities to the code he / she is more than welcome to do so. Please give some feedback and observations as this is my first project that i have uplaoded. if you find certain ways that i can improve on, please let me know so.


This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


About the Author

Web Developer
India India
No Biography provided

Comments and Discussions

Generalsdsdada Pin
Member 328049127-May-15 12:27
MemberMember 328049127-May-15 12:27 
QuestionNeed more funcition Pin
Dark_traveller10-Mar-13 23:10
MemberDark_traveller10-Mar-13 23:10 
GeneralMy vote of 4 Pin
mukesh_panth19-Dec-12 1:23
professionalmukesh_panth19-Dec-12 1:23 
QuestionRich text box with hyperlink attach to the text Pin
Member 779443228-Nov-12 17:44
MemberMember 779443228-Nov-12 17:44 
GeneralMy vote of 5 Pin
sunnyuppal338-Feb-12 6:58
Membersunnyuppal338-Feb-12 6:58 
GeneralMy Vote of 5 too Pin
THE SK1-Feb-11 21:23
MemberTHE SK1-Feb-11 21:23 
GeneralMy vote of 5 Pin
shailendra_ec200330-Nov-10 20:24
Membershailendra_ec200330-Nov-10 20:24 
GeneralOnBlur event of Iframe is not working in Firefox Pin
Chandra.Anumakonda7-Dec-09 3:37
MemberChandra.Anumakonda7-Dec-09 3:37 
GeneralNeed help to set values in Richtextbox Pin
gopikrishnan.in2-Aug-09 8:28
Membergopikrishnan.in2-Aug-09 8:28 
GeneralRe: Need help to set values in Richtextbox Pin
gorkemdur17-Feb-11 0:00
Membergorkemdur17-Feb-11 0:00 
GeneralRich text Box Pin
chamieshani29-Apr-09 23:57
Memberchamieshani29-Apr-09 23:57 
GeneralRichTextControl Pin
pwicks24-Mar-09 4:28
Memberpwicks24-Mar-09 4:28 
GeneralNot seeing the methods Pin
jshiv12-Mar-09 8:50
Memberjshiv12-Mar-09 8:50 
GeneralSetting Default Message Pin
Govind Gopal29-Dec-08 5:19
MemberGovind Gopal29-Dec-08 5:19 
QuestionRTB with IE7 Pin
ToCentre25-Sep-08 23:58
MemberToCentre25-Sep-08 23:58 
GeneralNO GO Pin
Member 363694022-May-08 9:16
MemberMember 363694022-May-08 9:16 
GeneralThanks. I find it usefull Pin
Abdul Bakour15-Apr-08 11:45
MemberAbdul Bakour15-Apr-08 11:45 
Generalnot working in mozilla Pin
na_k2-Apr-08 1:42
Memberna_k2-Apr-08 1:42 
GeneralRe: not working in mozilla Pin
na_k3-Apr-08 4:49
Memberna_k3-Apr-08 4:49 
GeneralRe: not working in mozilla Pin
ankurgupta41428-Aug-09 2:33
Memberankurgupta41428-Aug-09 2:33 
GeneralSetting Default Message Pin
sujanakar6-Oct-07 2:28
Membersujanakar6-Oct-07 2:28 
GeneralRe: Setting Default Message Pin
jimmy.jiang26-Jun-08 23:44
Memberjimmy.jiang26-Jun-08 23:44 
Generalnice work Pin
multimedia921-Sep-07 6:36
Membermultimedia921-Sep-07 6:36 
GeneralRe: nice work Pin
Steve Maier21-Sep-07 8:24
professionalSteve Maier21-Sep-07 8:24 
GeneralRe: nice work Pin
s.kushal22-Sep-07 2:42
Members.kushal22-Sep-07 2:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Posted 20 Sep 2007


36 bookmarked