I have tried with mouse leave function in jquery with the following code
$(function () {
$("#<%=txt_FromDate.ClientID %>").mouseleave(function () {
// alert("Wow; Its Work!.")
var txt_FromDate = document.getElementById('txt_FromDate');
var txt_ToDate = document.getElementById('txt_ToDate');
txt_ToDate.value = txt_FromDate.value;
});
});
The above code is working fine when mouse leave from the text box. but i need the effect when clicking calender txt_FromDate(from date) and it effect the same date in txt_ToDate(to date).
My html code is given below
<td style="text-align: left;" class="auto-style1">
<asp:TextBox ID="txt_FromDate" runat="server" class="inputCalendar2_font14" Width="105px"
onfocus="showCalendarControl(this);" onkeypress="return false;" onpaste="return false;"
CssClass="inputCalendar2_font14"></asp:TextBox>
<asp:TextBox ID="txt_ToDate" runat="server" class="inputCalendar2_font14" Width="105px" OnTextChanged="txt_ToDate_TextChanged"
onfocus="showCalendarControl(this);" onkeypress="return false;" onpaste="return false;"
CssClass="inputCalendar2_font14"></asp:TextBox>
My reference is given below,
<script src="../jScript/BrowserCompatibility.js" type="text/javascript"></script>
<script src="../jScript/jquery-1.4.4.js" type="text/javascript"></script>
<script src="../calenderCtr/CalendarControl.js" type="text/javascript" language="javascript"></script>
<link href="../calenderCtr/CalendarControl.css" rel="stylesheet" type="text/css" />
<script src="../jScript/Validator.js" type="text/javascript" language="javascript"></script>
<link href="../style/dsi_mig.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>
<script type="text/javascript">