PRB: SET CENTURY OFF is Ignored if Date is Over Year 2000

Last reviewed: March 20, 1998
Article ID: Q169471
The information in this article applies to:
  • Microsoft Visual FoxPro for Windows, versions 3.0, 3.0b, 5.0, 5.0a

SYMPTOMS

"SET CENTURY OFF" is ignored within text box of a form if the date type is set to "Taiwan" and the date is over "1/1/2000."

RESOLUTION

Convert the Date with the DTOC() function.

MORE INFORMATION

Steps to Reproduce Behavior

In the Command window, issue following commands:

   SET DATE to Taiwan
   SET CENTURY OFF
   *** Note : Year 2000 is equivalent to Taiwan Year 0089
   ? {89/01/01}

"89/01/01" displays on the FoxPro desktop (or in the active window).

Place the same setting within a text box of a form and set the "Readonly" property to .F. The result is "0089/01/01."

  1. Add a TextBox control within a form.

  2. Change the property "Century" of the TextBox to "0 - Off."

  3. Change the property "DateFormat" to "8 - Taiwan."

  4. Change the "value" of the TextBox to {89/01/01}, which is January 1, 2000, and run the form.

NOTE: The display of the TextBox will be "0089/01/01." The TextBox value,
      however, is "89/01/01."
Keywords          : FxenvOs FxprgSet vfoxwin
Version           : 3.00 3.00b 5.00 5.00a
Platform          : WINDOWS
Issue type        : kbprb


================================================================================


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: March 20, 1998
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.