# Function Reference

# _DateIsLeapYear

Checks a given year to see if it is a leap year

#include <Date.au3>
_DateIsLeapYear ( $iYear )

## Parameters

$iYear | The 4-digit year to check.

## Return Value

Success: | 1.
Failure: | 0 if the year is not a leap year and sets the @error flag to non-zero.
@error: | 1 - Invalid year.

## Example

    #include <Date.au3>
    #include <MsgBoxConstants.au3>

    If _DateIsLeapYear(@YEAR) Then
        MsgBox($MB_SYSTEMMODAL, "Leap Year", "This year is a leap year.")
    Else
        MsgBox($MB_SYSTEMMODAL, "Leap Year", "This year is not a leap year.")
    EndIf