Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

JavaScript Forum


You are currently viewing our JavaScript Forum as a guest. Please register to participate.
Login



Reply
Textarea GotoLineNumber
Old 03-27-2009, 12:31 PM Textarea GotoLineNumber
Skilled Talker

Posts: 64
Name: Ralph Freshour
Trades: 0
I want to write a function that will let me position my cursor in a textarea on a line number. I'm confused on what functions/methods I would need to use on a textarea component to do this.

I'd like to popup a dialog in JS so I can ask the user what line number and then have the cursor go to that line - is this even possible?

Thanks...
__________________
RalphF
Business Text Messaging Services

Please login or register to view this content. Registration is FREE
rfresh is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 03-29-2009, 01:38 PM Re: Textarea GotoLineNumber
Sleeping Troll's Avatar
Ultra Talker

Posts: 351
Name: Butch Begy
Trades: 0
You will have to format the text in the text area, of course if the user is entering the text this will not be possible. To see why this is, just resize your text box and watch the text rewrap. The text is an unformatted string. all you can count is characters.

Also I can tell by your language that you are not completely familiar with "oops", you need to get that way. if you need help contact me.

I believe what you are trying to achieve is possible (most things are) just not the way you are approaching it.
__________________
Sleeping Troll, EMUSE, Mind Expansion...Truly serendipity!

Last edited by Sleeping Troll; 03-29-2009 at 01:43 PM..
Sleeping Troll is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Textarea GotoLineNumber
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.13279 seconds with 12 queries