Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Set century
Message
De
12/05/2005 12:26:09
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Database:
Visual FoxPro
Divers
Thread ID:
01013353
Message ID:
01013485
Vues:
11
CLEAR

set century TO 19 ROLLOVER 55   && default

?SET("century",2)  &&55

***************** FABIO *************
* Attention, next have a 1..100 range, but rollover's range is 0..99
lnyear=VAL(RIGHT(DTOC(DATE()),2))+1

* Doc
* SET CENTURY ON | OFF | TO [nCentury [ROLLOVER nYear]]

set century ON at this point the Parser ignored anythings
***************** FABIO END ****************

set century ON TO 19 ROLLOVER lnyear    

?SET("century",2)   && still 55, why?

for i=1 to 10
	?ctod('01/01/'+ transform(m.i))  && rollover 6 does not work
NEXT

set CENTURY TO 19 ROLLOVER lnyear

?SET("century",2)   && now it is 6, because of ON was removed?
for i=1 to 10
	?ctod('01/01/'+ transform(m.i))   && rollover 6 works
NEXT

* Try with ON again
set CENTURY ON TO 19 ROLLOVER lnyear 

?SET("century",2)     && it is 6 however, why?
for i=1 to 10
        ?ctod('01/01/'+ transform(m.i))  && rollover 6 works, and with ON !?
NEXT
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform