Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
GETFILE() change my path?
Message
De
25/08/2005 13:28:24
 
 
À
25/08/2005 12:33:19
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9
Divers
Thread ID:
01043785
Message ID:
01043983
Vues:
11
Getfile() does not change SET PATH.

>GETFILE() does change the "SET PATH" if a result is returned so you need to reset your path name after retrieving a result. Something like:
>
>lcPath = SET( "PATH" )
>lcFileName = GETFILE( lcFileName, "imp",  "Import File" )
>SET PATH TO lcPath
>
>While looking this up I found a bug fix comment in the same program relating to the use of LOCFILE() vs. GETFILE() which I found interesting. I'll just copy the comment here:
>
>* 1. Replace LOCFILE() function with GETFILE().  Primary difference is when
>*    the user presses "cancel" on GETFILE() an empty string is returned. . .
>*    OTOH, when pressing "cancel" with LOCFILE() VFP displays an error with
>*    which one of the options cancels VFP entirely -- not too cool.
>
>Scott
Groet,
Peter de Valença

Constructive frustration is the breeding ground of genius.
If there’s no willingness to moderate for the sake of good debate, then I have no willingness to debate at all.
Let's develop superb standards that will end the holy wars.
"There are three types of people: Alphas and Betas", said the beta decisively.
If you find this message rude or offensive or stupid, please take a step away from the keyboard and try to think calmly about an eventual a possible alternative explanation of my message.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform