[AccessD] detect network

Gustav Brock gustav at cactus.dk
Thu Jun 19 09:00:23 CDT 2003


Hi Bruce

> You could either use the network API calls to get the network connection
> information or presumably when they are connected there will be a
> network path name you could try to access to see if its connected.

> The network path is probably the QAD method.

That will probably be the SAD method - awaiting a timeout.

Go the API route or dump and check the output of netstat or

  net use [some network drive] > netcheck.txt

Parse the first line of this for the network drive and the colon.
If the drive does not exist the file will be empty.

/gustav


> We've got a data collection application that will be run on disconnected
> laptops.  At least once a week the laptop users will come in to the home
> office to dump the data they've collected into our central SQL database.
> Does anyone have any code that will detect that the laptop is connected
> to our network so we can point their connection to the central DB (as
> opposed to their local DB)?  Or should we just try to hit the central DB
> at app start and trap the error?  I don't want to generate an error if I
> don't have to.



More information about the AccessD mailing list