Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I check to see if a network connection (i.e. mapping) is alive

Status
Not open for further replies.

ugagrad

Programmer
Sep 12, 2003
49
US
I was wondering how I could check to see if a mapping is still currently available. (i.e if the server is shutdown) I need to know before I perform other tasks on the server.
Thank you [auto]
 
ugagrad,

I believe this question is a duplicate of the question you asked in thread184-673274 where other members have started to answer you with a very workable and probable solution. Please try the solution(s) proposed there and if you still can't get it to work then post back in that thread. It will keep the forum cleaner and keep members from duplicating posts.

Slighthaze = NULL

[ul][li]FAQ184-2483
An excellent guide to getting a fast and accurate response to your questions in this forum.[/li][/ul]
 
Is this post a duplicate? You seem to be asking the same question as your last post, where suggestions were offered.

Mike Gagnon

If you want to get the best response to a question, please check out FAQ184-2483 first.
 
ugagrad,

You also created the previous thread184-674869 and all of these seem to be dealing with the same issue. Please try and stay within the framework of this forum and not create clutter like this. Thank you.


Slighthaze = NULL

[ul][li]FAQ184-2483
An excellent guide to getting a fast and accurate response to your questions in this forum.[/li][/ul]
 
Sorry guys,
none of the other posts have given me a clear answer. I thought maybe my question was not clear so I posted to this thread. Does anyone have a clear answer.
Thanks
Sorry for all of the clutter [sadeyes]
 
You've already utilized one of the best ways, using IF FILE()... (as written in one of your other posts).
Since drive mappings are not necessarily connected to their servers at startup, there isn't a way to check server availability until it is actually accessed. Using FILE() or ADIR() are both good, but the only way you are going to reduce the time the client takes to timeout and give you an error back, is to change your own or even the server's timeout settings.



-Dave S.-
[cheers]
Even more Fox stuff at:
 
Is there any way just to check if the connection is alive(connected, etc.). Thanks everyone for your help in advance.
 
ugagrad,

like dave said (Since drive mappings are not necessarily connected to their servers at startup, there isn't a way to check server availability until it is actually accessed.). i use the FILE( ) and DIRECTORY( ) functions to check if the server is available or not and both work great for me.

kilroy [trooper]
 
The other way to do this is to know what the static IP address is for the server...such as 192.168.0.1 and to use this in order to PING the server as has been suggested previously. The PING should return faster than the File() or DIRECTORY() functions but you are going to have to write a little more code to make it happen.

Using these suggestions and perhaps a little message for the user such as "Checking for Server Availability One Moment Please..." should work pretty well. If there is a reason that such a solution doesn't work for you, please post back and I am sure we can figure out a solution that is right for you. But try what you've been given here first and let us know how it went for you.

Slighthaze = NULL

[ul][li]FAQ184-2483
An excellent guide to getting a fast and accurate response to your questions in this forum.[/li][/ul]
 
You can ping a server name on a LAN too, not just an IP.

Brian
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top