Click here to Skip to main content
14,326,246 members
Rate this:
Please Sign up or sign in to vote.
See more:
I have multiline textbox. i can enter 80 characters per line and there are 10 lines such. Now when user is typing, i want to display what is the number of character and what is the line number?

For ex : in first line if user enter "Hi Hello" then in label it will display Character : 8/80 (" is just the phrase)
Posted
Comments
Sunasara Imdadhusen 15-Nov-10 23:01pm
   
I will help you, but you should provide snippet of your code!
Sandeep Mewara 16-Nov-10 11:34am
   
Update from OP:
i have a javascript restricting 80 characters per line and there are 10 lines. Now i want to display in label which number of character i am entering in which line. lets say line 1 completes, then line 2 start with character number 0.

ex : Hi Hello


Character : 8/80
Line : 1

ex : Hi
Hello

Character : 5/80
Line : 2

Now in example 2 if i move my cursor to Hi..... it should say Line 1 and character number is "X".

Thanks

1 solution

Rate this:
Please Sign up or sign in to vote.

Solution 1

Hi have a look Here[^].
This is JQuery based solution. try to implement jquery. Learn JQuery[^]

Thanks.
   

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100