Atomic Shrimp
Humanoid lifeform
- Local time
- Today, 18:03
- Joined
- Jun 16, 2000
- Messages
- 1,953
I have an application that runs on a scheduled hourly basis, it's querying linked tables that reside on the file server.
Because of the type of operations it's doing (also deleting temporary objects from the server and reimporting) it cocks up terribly if it tries to run if the server is down and the network drive is therefore not available.
So, I thought, all I need to do is create a file called "ImHere.txt" on the network drive and then just do:
If Dir "G:\ImHere.txt" = "" then
'Email the IT dept
'Shut down the app
End If
but the trouble is that if the network is down, the Dir function returns the error "device unavailable", so my idea doesn't really work.
Any suggestions?
Mike
Because of the type of operations it's doing (also deleting temporary objects from the server and reimporting) it cocks up terribly if it tries to run if the server is down and the network drive is therefore not available.
So, I thought, all I need to do is create a file called "ImHere.txt" on the network drive and then just do:
If Dir "G:\ImHere.txt" = "" then
'Email the IT dept
'Shut down the app
End If
but the trouble is that if the network is down, the Dir function returns the error "device unavailable", so my idea doesn't really work.
Any suggestions?
Mike