Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Checking the A: drive
Message
De
09/09/1996 12:07:25
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00007467
Message ID:
00007470
Vues:
34
>How can I check to see if a disk has been inserted into the A: drive before I receive a system message?
>
>Thanks,
>Don Pollock

Try this:

Function Test()
Local lnError

* Initialize the flag
lnError = 0

* Trap the errors
ON ERROR DO ErrHand With ERROR(), @lnError

* Try to open an unexistent file just to trap errors
= FOpen("A:\XPTO.TXT")

If lnError != 0 && No errors, keep on working
...
EndIf

* The error handler follows...
Return
Alexandre Nobre
Alpha Bytes Computer Corp.

Did you know that there are innocent people dying in East Timor?
It helps if you do...

I suppose you don't need glasses if you're able to read this line

Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform