>James,
>
>If SET DATE SHORT the DTOC(DateField) gives 7/2/00. If SET DATE LONG, DTOC(DateField) Saturday, July 01, 2000. What I need (and had with VFP5) is 07/01/2000. I have a LOT of legacy code that grabs the year by using SUBSTR(DTOC(DateField),7,4).
Rudy,
I suggestion, if you don't mind. I'd change that legacy code to use the YEAR() function ASAP, even if the value needed is character (you could use TRANSFORM() in 6.0). The reason I say this is that YEAR() always returns 4 digits (regardless of the date settings) and isn't impacted by any regional date settings (for example, DMY). If I recall correctly it was available when the DTOC() function was introduced (2.0??) and if the code was written in 2.5 or above and is still in use, there shouldn't be any problems caused by this change.
George
Ubi caritas et amor, deus ibi est