I want textbox to automatic call jQuery when the text/value changed. At the start, the readonly owner textbox is empty. I only can select the name and then it will automatic paste the name to tbAdd_Powner
textbox. After it pasted, I want it to automatic call it jQuery to get value from tbAdd_Powner
textbox and pass it to txtPass
textbox. For example, I select Joe then it will paste Joe in tbAdd_Powner textbox
then it call jQuery to pass Joe to txtPass
textbox.
I tried the codes below and it doesn't work.
Here is jQuery and html example,
<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="testtest.aspx.cs"
Inherits="testtest" EnableEventValidation="false" Async="true" MaintainScrollPositionOnPostback="true" %>
<script language="javascript" type="text/javascript">
$(function () {
$('#tbAdd_Powner').on('input',function () {
alert("It Changed!");
$('#txtPass').val($('#tbAdd_Powner').val());
});
}); </script>
<asp:TextBox ID="tbAdd_Powner" runat="server" ClientIDMode="Static" Enabled="false"></asp:TextBox>
<asp:TextBox ID="txtPass" runat="server" Width="163px"></asp:TextBox>