Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
how to determine if a var is = nothing
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00413285
Message ID:
00413296
Vues:
19
>I have a var that will either be an ObjectReference or Nothing and I need to determine that with if.
>
>I tried: "if MyVar is Object", but I get an error.
>
>tia

I think that

if type("MyVar") = "O" and !isnull(MyVar)

or

if vartype(MyVar) = "O" and !isnull(MyVar)

is what you need.

...Y soy feliz, bien feliz, asi lo grito;
Mira, que el mundo sepa, que se sepa:
Soy feliz....                       

...And I'm happy, quite happy, so do I yell it;
Look, so the world knows it, so be known:
I'm happy...
 

Ismael Rivera "Oye cosita linda"
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform