Gayatri Pattar

Gayatri Pattar

  • 2k
  • 25
  • 68.9k

how to clear textbox after alert in javascript?

Dec 30 2013 6:25 AM
Hi,
 
 After selecting date from calender control if the date is out of range it should display alert message after clicking ok on alert message  ,the date appeared in textbox should get cleared.
 
I have written javascript as follows
 
<script type="text/javascript">
function CheckDueDate(sender,args)
{
if (sender._selectedDate >= 31 / 05 / 1995 || sender._selectedDate <= 01 / 06 / 1948)
{
alert("Age should be in between 18 to 65");
}
}
</script> 
 
It shows message but m not able to clear the textbox. Please Help me.
 
 
 
 
 
 

Answers (2)