How to make an editor with line number

Hi, in visual studio, when you show line number, you can see that the line number column is uneditable, and the line number column can be scroll with the text. Furthermore, the line number increase and decrease according to the typing of user.

I wish to build such an editor using visual studio(C#), but I am not sure which component to use, and how to achieve that. Can anyone shed me some light?
LVL 9
william007Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

srinivasbnCommented:
Hi

I have a solution to do the editor. You can't do it normal text editors. But you can do the same using the datagrid control. Use 1st column as display numbers and in the second column the text what you want to display or enter.

Suppose you are entering the text and after finishing the line you click on enter key then automatically it should add the new row and place the control at the new row second column.
Write the code when ever the new row is inserted then automatically you should add then new line number.

I think this will solve your problem
0
Jaime OlivaresSoftware ArchitectCommented:
there are some free ready-made custom controls at codeproject.com, like:
http://www.codeproject.com/KB/edit/numberedtextbox.aspx
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Jaime OlivaresSoftware ArchitectCommented:
0
william007Author Commented:
Thank :)
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
.NET Programming

From novice to tech pro — start learning today.