Skip to content

Instance Property

dayOfYear

iOS 18.0+ iPadOS 18.0+ Mac Catalyst 18.0+ macOS 15.0+ tvOS 18.0+ watchOS 11.0+
A day of the year. For example, in the Gregorian calendar, can go from 1 to 365 or 1 to 366 in leap years.
var dayOfYear: Int? { get set }

Discussion

Note

This value is interpreted in the context of the calendar in which it is used.