Home | Javascript validator | JavaScript Editor JavaScript EditorGet Advanced
JavaScript and Ajax Editor,
Validator and Debugger!

1st JavaScript Editor.
Microsoft® JScript®
getMilliseconds Method
 Language Reference 
Version 3 

See Also                  Applies To


Description
Returns the milliseconds value in a Date object using local time.
Syntax
objDate.getMilliseconds()
Remarks
To get the number of milliseconds in Universal Coordinated Time (UTC), use the getUTCMilliseconds method.

The millisecond value returned can range from 0-999.

The following example illustrates the use of the getMilliseconds method:

function TimeDemo()
{
  var d, s = "The current local time is: ";
  var c = ":";
  d = new Date();
  s += d.getHours() + c;
  s += d.getMinutes() + c;
  s += d.getSeconds() + c;
  s += d.getMilliseconds();
  return(s);
}

Home | Javascript validator | JavaScript Editor JavaScript EditorGet Advanced
JavaScript and Ajax Editor,
Validator and Debugger!

1st JavaScript Editor.