Added March 2009
xcall MIAMEX, MX_CHKPCNET, status, flags {,clisvr}
MX_CHKPCNET checks the network state of the local PC (for A-Shell/Windows) or the ATE client:
See the Tab(-10,x) Function Listing for an equivalent Print Tab command (AG_CHKPCNET).
status (Num) [out]
will return 1 if the PC is connected to the Internet, and 0 if it is not. -1 indicates that the function is not supported (not Windows, ATE not present, or ATE PC version too old), and -15 indicates that ATE did not respond.
Note that since older versions of A-Shell would not have this function supported, you may want to pre-set status to something like -99 so you don't confuse a non-updated status with a real one (or, use MX_GETVER to check the A-Shell version before calling the function).
Notes also for ATE: if A-Shell on the server is 1138.3 or higher, but the ATE PC is not, the function returns STATUS = -1.
flags (Num) [out]
returns flags which can be interpreted as following:
Symbol |
Value |
Meaning |
INTERNET_CONNECTION_CONFIGURED |
&h0040 |
local system has a valid connection to the Internet, but it might not be connected. |
INTERNET_CONNECTION_OFFLINE |
&h0020 |
local system is in offline mode |
INTERNET_RAS_INSTALLED |
&h0010 |
|
INTERNET_CONNECTION_PROXY |
&h0004 |
local system uses a proxy server |
INTERNET_CONNECTION_LAN |
&h0002 |
local system uses a LAN to connect |
INTERNET_CONNECTION_MODEM |
&h0001 |
local system uses a modem to connect |
clisvr (String, 1) [in]
History
2011 July, A-Shell 5.1.1226: Add clisvr parameter.
2009 February, A-Shell 5.1.1139: Routine added to A-Shell.