Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Why INLIST() returns .T. ??
Message
De
02/10/2001 20:36:07
Peter Wagner
Point Informática Ltda.
Limeira, Brésil
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Why INLIST() returns .T. ??
Divers
Thread ID:
00563377
Message ID:
00563377
Vues:
45
Supose today is 10/02/01.
xdate = DATE() && Todays date
1)
? INLIST(ALLTRIM(STR(MONTH(xdate))),"1","2") && If Jan or feb (Returns .T. <<== ERROR)
* Here I expect .F.

2)
but if I do sometinhg like this..
STORE CMONTH(DATE( )) TO gcMonth
? INLIST(gcMonth,'January','February','March') && vorks fine ( Returns .F.)

3)
gcMonth = "Feb"
? INLIST(gcMonth,'January','February','March') && vorks fine ( Returns .F.)

Could someone explain Why I got an error in the first INLIST()
than inlist() search's for the "all" the expression in another set of expressions,
and Month() in this case returns 10, and I dont have "10" in the
expression list to match.
I thing if it just accept part of the string to match then it should
return .T. in the last sample.
What Im missing ?

TIA

Peter
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform