Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Is my buddy running?
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00426835
Message ID:
00426903
Vues:
25
>Hi!
>
> Try to use low-level file functions. For example, in App1 make file using FileCreate function. Close it and than use FOPEN("MyFile",12), that is similar to exclusive use. In the App2 use following to check if App1 is still running:
>
>  local lnHandle
>  lnHandle = FOPEN("MyFile",12)
>  IF lnHandle>0
>    FCLOSE(lnHandle)
>    && Application 1 don't working now
>    ...
>  ENDIF
>
>
>Above code does not require error handling, when working with exclusive tables require error handling.
>
>HTH.
>

Thanks. Although that is a cleaner implementation, I still have the same concerns though, will the file become "unlocked" if App1 crashes? Or will the OS hold that file?

I've experimented a little, and it looks "ok" but I want to be sure before I put it into code.

-Sam
If they have you asking the wrong questions,
they don't have to worry about the answers.
-proverbs for paranoids #3
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform