Click to See Complete Forum and Search --> : Inserting a value into an HTML textbox


December 12th, 1999, 06:02 AM
If I have a text box on a web page like this
<input type="text" size=20 name="textbox" id=textbox">
How do I insert a value into the text box using vbscript?

whg
December 12th, 1999, 07:49 AM
<input type="text" size=20 name="textbox" id=textbox" VALUE="Insert This">


whg

December 12th, 1999, 08:33 AM
I need to do it with VBScript not by setting the value before hand. Using JavaScript it would be something like this.
document.FormName.TextBox.value = "Hello World";

December 12th, 1999, 02:25 PM
<input type="text" size=20 name="textbox" id=textbox" VALUE="%varname&">

December 13th, 1999, 10:11 AM
Shouldn't your:
document.FormName.TextBox.value = "Hello World";

Actually be:
document.FormName.TextBox.Text = "Hello World";

Sudharshaan
December 28th, 1999, 04:10 AM
use
formname.textboxname.value ="XYZ" in any event..


Sudharshaan