GlideDateTime - getLocalDate()

Gets the date stored by the GlideDateTime object, expressed in the standard format, yyyy-MM-dd, and the current user's time zone.

Table 1. Parameters
Name Type Description
Table 2. Returns
Type Description
GlideDate The date in the user's time zone.

Scoped equivalent

To use the getLocalDate() method in a scoped application, use the corresponding scoped method: Scoped GlideDateTime - getLocalDate().

var gdt = new GlideDateTime("2011-08-31 08:00:00");

Output: 2011-08-31