Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Web Controls > Is it possible to get only the "Selected" text out of a TextBox

Reply
Thread Tools

Is it possible to get only the "Selected" text out of a TextBox

 
 
Chris Bates
Guest
Posts: n/a
 
      06-22-2006
Ok guys, here is what I am trying to do.

Lets say I have a TexBox server control on a page.

Lets say that TextBox has a bunch of text in it.

Lets say that a user uses thier mouse to select a small part of the text
then hits a button.

I would like to be able on that button push to trap / get only the text the
user has selected.

Anyone have any ideas, I am coming up with nothing on google.

Thanks

Chris
 
Reply With Quote
 
 
 
 
Alessandro Zifiglio
Guest
Posts: n/a
 
      06-23-2006
hi Chris,
You are looking at writing some javascript to exclude the unselected text in
your textbox when your submit button is clicked, that should populate the
forms collection with the updated value in the textbox before the submit
occurs.
The following link might help you get started with the js you need to write.
http://www.quirksmode.org/js/selected.html
Good luck,
Alessandro Zifiglio
"Chris Bates" <(E-Mail Removed)> ha scritto nel
messaggio news:(E-Mail Removed)...
> Ok guys, here is what I am trying to do.
>
> Lets say I have a TexBox server control on a page.
>
> Lets say that TextBox has a bunch of text in it.
>
> Lets say that a user uses thier mouse to select a small part of the text
> then hits a button.
>
> I would like to be able on that button push to trap / get only the text
> the
> user has selected.
>
> Anyone have any ideas, I am coming up with nothing on google.
>
> Thanks
>
> Chris



 
Reply With Quote
 
 
 
Reply

Thread Tools

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 On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Textbox, Input (text) on turbotax... anyone know which 3rd party textbox this is??? pld888@gmail.com ASP .Net 3 02-23-2007 08:51 PM
XML + XSD: Is it possible to get all possible Values for an Element? Markus Java 1 11-22-2005 02:51 PM
ASP.NET textbox loses text value in composite control but Textbox subclass doesn't!? ErwinP ASP .Net Web Controls 1 08-19-2005 01:50 PM
writing two textbox's text in one textbox agb ASP .Net Web Controls 1 08-27-2003 12:57 AM
Get text in TextBox without pressing Enter key mg ASP .Net 5 07-14-2003 02:09 PM



Advertisments