>I guess I'm confused about the use of the SET CENTURY command in private data sessions (VFP 5.0a). I created a test form with three text boxes. I set the form to the default data session and typed the following in the command window...
>
>SET CENTURY TO 19 ROLLOVER 60
>
>In the Init of the form I have...
>
>WITH THISFORM
> .Txt1.Value = DATE()
> .Txt2.Value = {11/29/45}
> .Txt3.Value = {11/29/65}
>ENDWITH
>
>When I run the form I get what I expect, 11/29/1998, 11/29/2045, 11/29/1965.
>
>However, when I change the form's data session to private and put the SET CENTURY TO 19 ROLLOVER 60 in the Init of the form (or in the Load) and run the form I get: 11/29/98, 11/29/2045, 11/29/65. So, what am I missing here???
If you are referring to the missing 1900, it's just because you forgot to
SET CENTURY ON
in your
Init/load event.
SET CENTURY ON
is also scoped to the current datasession. By default, century is off in VFP5, so your form's datasession has that default as well.
Sylvain Demers
Sylvain Demers