Selecting partial text within <INPUT TYPE=

Results 1 to 2 of 2

Thread: Selecting partial text within <INPUT TYPE=

  1. #1
    Join Date
    Dec 1969

    Default Selecting partial text within <INPUT TYPE=

    Greetings . . .<BR><BR>Does anyone know how to automatically select partial text within an input text field? In other words, let&#039;s say I have a text field with the string "TESTING" in it, and I want to select "STING" (equivalent to taking my mouse, putting the cursor before the "S," and dragging to the end of the string so that "STING" is highlighted/selected).<BR><BR>I have to be able to do this using DHTML (or even VBScript). Does anyone know how to do this? For that matter, is it even possible?<BR><BR>Help!!!

  2. #2
    Join Date
    Dec 1969
    Los Angeles, CA

    Default Well i guess

    TextBoxName.SelStart = x<BR>TextBoxName.SelLength = y<BR><BR><BR>Where x is the start position you want to highlight from and y is the number of characters you want to highlight.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts