>Sorry but I don't understand VFP documentation in this matter. Please somebody help.
>I have a field in which a date should be entered. I want that field being a text field that'll convert to date afterwards, and I want the user to enter the last two digits of the year only.
>First problem: I set the Input mask to ##/##/19## so that the user doesn't have to enter the whole year, but the field only displays / /1 (the 9 is missing) ??
The digit 9 is a special Input mask character (like '#' you are using) that indicates a position where digits and signs, such as a minus (-) sign can be entered.>Second problem:
> This field calculates the age of a person. But if I enter a date with a 2 digit year lower than 1950, it calculates a negative number. I've read the documentation regarding the SET CENTURY stuff, but frankly I don't understand what to do with the SET CENTURY TO and ROLLOVER thing to accomplish this.
If you didn't change SET CENTURY ON TO ... ROLLOVER ... setting than the century value would be 19 and the rollover value would be 51 (the last two digits of the current year plus 50 years: 01 + 50 = 51). It means that any 2 digit year yy equal or greater than 51 will belong to 19yy (the current century) and any 2 digit year yy less than 51 will belong to 20yy. If you SET CENTURY 19 ROLLOVER 0 than all 2 digit years will belong to 19yy. Or you can add "19" to your text date year before converting it to date preventing foxpro from 'guessing' the century>TIA
>Ulises.
--sb--