Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
YEAR() ?
Message
From
07/06/2001 17:15:30
Cindy Winegarden
Duke University Medical Center
Durham, North Carolina, United States
 
 
To
07/06/2001 16:59:45
Chuck Tripi
University of Wisconsin - Milwaukee
Milwaukee, Wisconsin, United States
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Title:
Miscellaneous
Thread ID:
00516651
Message ID:
00516674
Views:
9
"Budget Year: " + IIF(DATE() <= DATE(YEAR(DATE()),6,30), ;
    ALLTRIM(STR(YEAR(DATE()) - 1)) + " - " + ALLTRIM(STR(YEAR(DATE()))), ;
    ALLTRIM(STR(YEAR(DATE()))) + " - " + ALLTRIM(STR(YEAR(DATE()) + 1)))
>Can you explain to me little more please? How this is put into this command line? I rather not change the SET DATE/CENTURY.
>
>>Instead of using {} for dates, I'd change formats to either
>>{^YYY-MM-DD} or use DATE(YYY,MM,DD)
>>
>>>VFP 6.0
>>>
>>>"Budget Year: "+IIF(DATE()<={06/30/}+YEAR(DATE()), ALLTRIM(STR(YEAR(DATE())-1))+" - "+ALLTRIM(STR(YEAR(DATE()))), ALLTRIM(STR(YEAR(DATE())))+" - "+ALLTRIM(STR(YEAR(DATE())+1)))
>>>
>>>This command line does work with Option: General, Year 2000 Compliance, Strict Date Level: 0-Off but not with 1-Constants.
>>>
>>>Can someone help correct this? I get the error message of Ambiguous Date/DateTime constant. I have the "1-Constants" set as Default (is that good?).
>>>
>>>Thank you.
>>>
>>>Chuck
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform