Forum Discussion

nebsta's avatar
nebsta
Contributor
9 years ago
Solved

UTC DateTime in JScript

Hi,   I am testing a WPF application where all DateTimes are in UTC - I need to be able to set a parameter to the current UTC date time but JScript doesnt seem to be able to support this e.g. if I ...
  • NisHera's avatar
    9 years ago
    function datett(){
    var d = new Date();
    var n = d.getUTCDate();
    var h = d.getUTCHours();
    var m = d.getUTCMinutes();
    var s = d.getSeconds();
    Log.Message('Today is '+n+'th .and now time is '+h+' Hours..and '+m+'  minutes and '+s+'  second');
    }

    dose this helps?