From: sindhoor on
call javascript function "showdate" from

CalendarExtender OnClientShowing="showDate"

<script>
function showDate(sender,args)
{
if(sender._textbox.get_element().value == "")
{
var todayDate = new Date();
sender._selectedDate = todayDate;
}
}
</script>



sindhoor wrote:

sorry I had missed few parts of the code in my previous post
07-Oct-09

<asp:TextBox ID="txtDate" runat="server" ></asp:TextBox>

<cc1:CalendarExtender ID="CalendarExtender1" runat="server" TargetControlID="txtDate" Format="MM/dd/yyyy" OnClientShowing="showDate" > </cc1:CalendarExtender>

<script type="text/javascript" language="javascript">

function showDate(sender,args)
{
if(sender._textbox.get_element().value == "")
{
var todayDate = new Date();
sender._selectedDate = todayDate;
}
}

</script>

EggHeadCafe - Software Developer Portal of Choice
HTML Horizontal Bar Chart
http://www.eggheadcafe.com/tutorials/aspnet/58a3094c-3e00-4d40-ab76-3370bea2c012/html-horizontal-bar-chart.aspx