|
|
How Can I Get Network Information for the Current User?The answer to this is very simple if your user is running Windows 95, 98 or ME. You can't. These operating systems don't support the API calls required to get information about the network environment. However, if your user is running Windows NT, 2000 or XP, the example below demonstrates how this can be done. It retrieves the username, logon server name and logon domain name for the currently logged in user, as well as a list of all global groups that user belongs to. Get Network Info - Windows NT/2000/2003 Only (18 KB) How Can I Get the IP Address of the Current Computer?This example showing how to retrieving the IP address for a computer requires a long and complicated series of Windows API calls. However, it is one of the few network-related utilities that operates on all versions of Windows from 95 onward. It's not something you'll need very often, but when you need it you really need it. How Can I Get Network Connectivity Information for the Current Computer?If your application depends on being able to connect to the network or some specific external destination, you should determine whether this connection can be made before you attempt to run. The example below shows how to determine whether the current computer is connected to the network as well as whether the current computer can connect to a specific external destination, such as a URL, IP address or computer name. |
|
Copyright Application Professionals © 1999 - 2013 |