isLeapYear ( )

Function stats

Average user rating
37
98
9999
Support
FileMaker 7.0 +
Date posted
05 December 2008
Last updated
15 May 2009
Version
Recursive function
No

Author Info
 Fabrice

74 functions

Average Rating 4.4

author_avatar



 

Function overview

Prototype

isLeapYear  ( _year )


Parameters

_year  


Description

Tags:  Date  

Returns 1 if the year is a leap year, else 0.

just because I see so many people trying to find out if a year is a leap year or not (which I don't even know why it could be helpful)

Examples

Sample input

isLeapYear ( 2004 )


Sample output

1

 

Function code

/* isLeapYear ( _year )

by Fabrice Nordmann


Returns 1 if the year is a leap year, else 0.

just because I see so many people trying to find out if a year is a leap year or not (which I don't even know why it could be helpful)

*/
Month ( Date ( 2 ; 29 ; _year )) = 2


// ===================================
/*

    This function is published on FileMaker Custom Functions
    to check for updates and provide feedback and bug reports
    please visit http://www.fmfunctions.com/fid/98

    Prototype: isLeapYear( _year )
    Function Author: Fabrice (http://www.fmfunctions.com/mid/37)
    Last updated: 15 May 2009
    Version: 1.2

*/
// ===================================

 

Comments

Agnès
23 January 2015



ou bien

not Mod ( _year ; 4 )

J'ai trouvé ça intéressant :)
  General comment
Fabrice
23 January 2015



ah ben non, c'est quand même un peu plus compliqué que ça :)
http://fr.wikipedia.org/wiki/Année_bissextile
  General comment
Agnès
23 January 2015



tu es là vite, oui, je viens de lire ce dernier lien et venait ici tout effacer :)
( mais je garde l'info, ça me plait ;) )
  General comment

 

 

 

 

 

Top Tags

Text Parsing  (33)
List  (31)
Date  (28)
XML  (26)
Format  (23)
Sql  (22)
Dev  (20)
Debug  (17)
Interface  (15)
Layout  (15)
Text  (14)
Variables  (12)
Layout Objects  (11)
Filter  (11)
Design  (10)
Array  (7)