Check if time is 'out of hours'

var gdt=gs.nowDateTime();
var gdtArr= gdt.split(' ');
var timeArr=gdtArr[1].split(':');
//var currenttime=parseInt(timeArr[0]);
gs.print(timeArr[0]);

if (timeArr[0]>=17 || timeArr[0]<8){

   gs.print('out of hours');
}

Comments

Popular posts from this blog

Running transform maps asynchronously

Post a command to the ECC queue for the mid server to initiate a powershell file copy

GlideRecord setValue