Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need help on automatic mirror textbox or duplicate text box.

Status
Not open for further replies.

kimly

MIS
Jul 11, 2000
7
US
Hi,
Does anyone know how to make <b>a mirror or duplicate textbox.</b>
For example, I have two textbox that are identical except its names. If I put numbers or words on the first textbox the 2nd one will Automatically showed up at the same time?

I wonder if it is possible. Please message me if you have any ideas.

Thanks

Kim ( kimly2002@hotmail.com ) [sig][/sig]
 
Hi,

This is pretty easy in IE...

Code:
<html>
<body>
 <form id=frmForm name=frmForm>
 Type in Here<input type=text id=txtBox1 name=txtBox1 onKeyUp=&quot;fnUpdate()&quot;><br>
 See it here as well<input type=text id=txtBox2 name=txtBox2 readonly>
 </form>
</body>
<script language=&quot;javascript&quot;>
 function fnUpdate(){
  var z=document.forms.frmForm;
  z.txtBox2.value = z.txtBox1.value;
 }
</script>
</html>

Hope this helps, [sig]<p>Rob<br><a href=mailto:robschultz@yahoo.com>robschultz@yahoo.com</a><br>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~<br>
"Focus on the solution to the problem,<br>
not the obstacles in the way."<br>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~[/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top