Rank: Newbie Groups: Member
Joined: 9/16/2008 Posts: 3
|
i am using the <eo:DatePicker runat="server" id="dpDate" control
when i am specify the onblur event like this dpDate.Attributes.Add("onblur", "CalculateAge(_eo_ctl00_cphMainContent_txtDOB_dpDate_picker,ctl00_cphMainContent_txtAge)")
the client side code is generated like this
<table border="0" cellpadding="0" cellspacing="0" id="ctl00_cphMainContent_txtDOB_dpDate" onblur="CalculateAge(_eo_ctl00_cphMainContent_txtDOB_dpDate_picker,ctl00_cphMainContent_txtAge)" style="width:100px;"> <tr> <td> <input style="font-family:Courier New;width:100%" type="text" id="_eo_ctl00_cphMainContent_txtDOB_dpDate_picker" name="_eo_ctl00_cphMainContent_txtDOB_dpDate_picker" value="07/14/1990" size="11"/></td><td><img id="_eo_ctl00_cphMainContent_txtDOB_dpDate_popupimg" onload="eo_ObjLoaded('_eo_ctl00_cphMainContent_txtDOB_dpDate_popupimg');" alt=" " title="" src="/RSIS.Net/eo_web.ashx?id=f41bf6b7-0a28-45d6-8c6b-9f904085d669" /> </td> </tr> </table>
the onblur event is not working because
date control is generating the table and rows and row contain the textbox when i specify the onblur event it assign to the table not for th textbox
i want to specify the onblur event for _eo_ctl00_cphMainContent_txtDOB_dpDate_picker
instead of eo_ctl00_cphMainContent_txtDOB_dpDate
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi, As you have noticed, the root element for the DatePicker is a table, not the textbox. In order to attach onblur to the textbox, you need to not only attach your own handlers to the textbox, but also call the original onblur handler (we handle onblur as well). The following post provided all the necessary code to do so: http://www.essentialobjects.com/Forum/Default.aspx?g=posts&t=1888Please let us know if that works for you. Thanks
|