GlideDateTime - getDayOfWeek()

Gets the day of the week stored by the GlideDateTime object, expressed in the user's time zone.

Use getDayOfWeekLocalTime() and getDayOfWeekUTC() instead of this method.

Table 1. Parameters
Name Type Description
Table 2. Returns
Type Description
Number The day of the week value - Monday = 1, ... Sunday = 7.

var gdt = new GlideDateTime("2011-12-01 12:00:00");

Output: 4