Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Connected to Network
Message
From
09/10/1998 09:36:40
 
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00144975
Message ID:
00145401
Views:
33
>>Anybody know a reliable way to determine if a workstation is connected to a network?
>>
>
>Lots of ways; but it depends on what exactly you're trying to determine - for example, are you trying to see if the station is currently logged into any network, or a particular network, or if a particular network resource has been (or can be) attached, or if the station -can- log into a network (IOW if the necessary client software is present to operate on a network, even if not logged in presently), or something else?


What I'm doing is creating a utility that shows files in use on a workstation or server. If the user is connected to a network, I want to show available servers, just like network neighborhood does. If not, I want to show the computer name.

I'm thinking that I can use WNetEnumResource and if it returns an error code, assume that I'm not connected and show the computer name. If it doesn't, show the servers.

Sound reasonable?

Greg
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform