DateTime d1 = DateTime.Now; DateTime d2 = yourObject.value; if (d2 > d1) { //your code }
function checkDate() { var fromDate=document.getElementById("<%=tcstartdate.ClientID%>").value.trim(); var toDate=document.getElementById("<%=tcenddate.ClientID%>").value; var record_day1=fromDate.split("/"); var record_day2=toDate.split("/"); if(record2 < record1) { alert("End date should be greater than start date"); return false; } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)