>>>>hello all
>>>>
>>>>is there any function for check if current year its a leap year ?
>>>>
>>>>txs
>>>
>>>Here's one-liner that uses VFP date arithmetic.
FUNCTION IsLeapYear(tnYear)
>>>RETURN ( (DATE(tnYear,03,01) - DATE(tnYear, 02, 01)) = 29 )
>>
>>How about:
>>
>>
>>RETURN !empty(date(tnYear, 3, 29))
>>
>
>Tere's 31 days in March so your code will always return .T.
Sorry, I meant February of course.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)