var gdt = new GlideDateTime(); var day = gdt.getDayOfWeek(); gs.print("getDayOfWeek="+gdt.getDayOfWeek()); gs.print("getDayOfMonth="+gdt.getDayOfMonth()); var result = false; if (day == 1 && gdt.getDayOfMonth()<=7){ result = true; } gs.print(result);
How to get first Monday of every month ServiceNow working code
Working Code Edited question August 11, 2023