Results 1 to 2 of 2
  1. #1
    Join Date
    Mar 2004
    Location
    Houston
    Posts
    1

    Question Unanswered: Ceasar (FoxPro 2.10 Y2K)

    Am looking for the Y2K patch for FoxPro v 2.10 (Dos) that will give me new date format...

    remove x's from my name should you wish to email me...

    Thanks

    Wil Engle

  2. #2
    Join Date
    Dec 2003
    Posts
    104
    Can you be a little more specific as to what exactly you need?
    Changing dates from say 01/01/99 to 01/01/1999 or 01/01/04 to 01/01/2004 can be done with SET CENTURY ON.
    This will add data to a table using the proper century. But if you have SET CENTURY OFF and add a date to a table as 01/01/04 then later browse or manipulate it, it could show up as 01/01/1904.
    There are all sorts of ways to validate the data even with CENTURY OFF, but if you don't need to do it then there's no reason to go through all your code to make the changes.
    What you would need to do though would be to establish a certain year which is basically the cut-off year, say, 1950. Anything less than the year 50, (1950) like 04, would be assumed to be 2004. Anything greater than 50 (99) would be assumed to be 1900's, or 1999. You would just have to create a function to determine the year and add 1000 years to the date.
    DSummZZZ

    Even more Fox stuff at
    www.davesummers.net/foxprolinks.htm

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •