Click here to Skip to main content
15,949,741 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have combobox(editable mode) & text box. I want find the text when combo box text is changed means when select one item then change the itemnae(text) or enter new value, those text i want to find and copy to text box and do some validations in my application. For this i wrote OnBlur event in javascript of combobox but its not fired, in this any wrong . This way of copying is right or any alternative for this. Pls help me..
Thanks in advance.
XML
<script type="text/javascript">
    function BatchnoChanged()
    {
    var cmb=document.getElementById("cmbBatchno");
    var txt=document.getElementById("txtBatchNo");
    txt.value=cmb.value;

    }
    </script>




XML
<asp:ComboBox ID="cmbBatchno" OnSelectedIndexChanged="cmbBatchno_SelectedIndexChanged" OnBlur="BatchnoChanged()"
                                                                                   ItemInsertLocation="Prepend"  runat="server" AutoPostBack="true"  DropDownStyle="Simple"
                                                                                   AutoCompleteMode="Append">
                                                                               </asp:ComboBox>
                                                                               <asp:TextBox ID="txtBatchNo" runat="server"></asp:TextBox>
Posted
Updated 23-Oct-13 1:44am
v3

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900