Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
@get displaying first 2 digits for year
Message
De
08/09/2005 00:47:17
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
07/09/2005 23:25:22
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01047568
Message ID:
01047599
Vues:
9
I see - the SET DATE is, indeed, not respected.

But you can change it as follows:
SET CENTURY OFF
ldTest = DATE()
@1,1 GET ldTest picture "@D"
read
For "picture" options, see the help topics for InputMask (equivalent to the PICTURE clause), and Format (equivalent to the FORMAT clause - can be included in PICTURE with the "@" sign).

>Try the following in your command window:
>
>
>SET CENTURY OFF
>ldTest = DATE()
>@1,1 GET ldTest
>
>
>
>
>>>The @get is displaying the first 2 digits for the year with set century off.
>>>We are seeing 20 instead of 05
>>>
>>>Is there a work around for this problem.
>>>
>>>We don't have the time right now to rework all the code and change all the screens to forms.
>>
>>I would say that you have SET CENTURY ON, even if you think otherwise - check with the debugger.
>>
>>In Visual FoxPro forms, each form can have a "private datasession"; meaning that an option like SET CENTURY can be ON in one form, and OFF in another, and have to be set in each individual form (if you use private datasessions). I don't think this should apply to screens ported from old FoxPro, but it may be a thing to check.
>>
>>You may also want to check the picture and size of the GET element.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform