如何将TextBox值绑定到SAME PAGE中的另一个文本框 [英] how to Bind the TextBox value to another Textbox in the SAME PAGE

查看:116
本文介绍了如何将TextBox值绑定到SAME PAGE中的另一个文本框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果选中CheckBox,TextBox值将绑定到同一页面中的另一个TextBox



请帮助我

if check the CheckBox, TextBox Value is Bind to Another TextBox In the Same Page

Please help Me

推荐答案

试试这个:



为复选框设置Autopostback = true

Try this:

Set Autopostback = true for checkbox
if(CheckBox1.Checked == true)
 {
     textbox1.Text = textbox2.Text;
 }


Use JQuery To Bind value in Another Text Box







<input type="checkbox" id="similaradd" />Similar To Above
<input type="text" id="txt1" />
<input type="text" id="txt2" />








#similaradd)。click( function (event){
val text1 =
("#similaradd").click(function (event) { val text1 =


这篇关于如何将TextBox值绑定到SAME PAGE中的另一个文本框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆