Long island web design, hosting company
Home About Us Support Products Services Portfolio Contact Us Home

Javascript > setDate Method

Created On: 11/24/2004 9:56:00 AM

Following example displays usage of setDate method in JScript. 'setDate methods sets the numeric date of the Date object using local time.
 var objDate, currentDate;         
 objDate = new Date();   
 objDate.setDate(newdate);
 currentDate = "Current setting is ";
 currentDate += d.toLocaleString();