Date.getDayOfYear

Syntax

PP.Date.getDayOfYear(date): Number;

Parameters

date. Date. Date.

Description

The getDayOfYear static method returns the day number in the year.

Comments

Returns day number starting from 0.

Example

To execute the example, add a link to PP.js scenario file to HTML page.

// Create the current date
date = new Date();
// Determine day number
day= PP.Date.getDayOfYear(date);
console.log(day);

After executing the example the current date day number is obtained.

See also:

PP