Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to find whether a workstation is connected??
Message
De
16/06/1999 00:15:42
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Titre:
How to find whether a workstation is connected??
Divers
Thread ID:
00230282
Message ID:
00230282
Vues:
60
I have this app running on an NT server.On it is a timer class that runs every 10 seconds with code in it. This code has only one purpose and that is to update the master database on the server with data from the workstation. I did this so that in the event of the WS going down the app on the server could still run and data from the WS entered manually. This was to avoid down time on the server just because the WS went down.

To ensure the WS is online I read a path to its data files from a config DBF with a virtual path and not a mapped path.

So even if the WS is mapped as g:\, I use the path \\workstation1\DATA\ as I found this to be faster and more reliable.
To find if the WS is actually running, the timer checks for the data file using code

IF FILE(DataPath+"WSTABLE.DBF")
DO update code
ELSE
Do not update
ENDIF

This happens every time the timer fires, so that even if the WS was offline, when it does come online, FILE() will pick it up.

All this works fine but when the WS actually goes down, The FILE() takes ever so long to return an .F. and slows the main app down terribly.

Is there any other way to check if a WS is online so that the update can be done without the server slowing down when the WS goes offline??
This defeats the purpose.

Any suggestions??

Bernard
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform