I am trying with this, but it is undignified.
In html.
<BDP:BasicDatePicker ID="DOBpicker" runat="server" CssClass="txtBox" DisplayType="TextBox"
ValidationGroup="userRegistration" />
in jquery, I tried with this
function btn()
{
var date = $('#DOBpicker').val();
alert(date);
}
or
function btn()
{
var date = document.getElementById('DOBpicker').value;
alert(date);
}
call this function on btn
<input id="test" type="button" value="go" onclick="btn()" />
But it undefined.
Try
attr()instead ofval(). See demo hereYou have to have value otherwise it doesn’t fire anything or just undefined. For instance I have added
value="Hello World"