Jump to Real's How-to Main page

Detect if a network is present

[external function declaration]
FUNCTION Integer GetSystemMetrics (Integer nIndex) LIBRARY "user32.dll"

[powerscript]
integer SM_NETWORK = 63

IF GetSystemMetrics(SM_NETWORK) > 0 THEN
    MessageBox("", "Network is up")
END IF
See this related HowTo
If you find this article useful, consider making a small donation
to show your supportfor this Web site and its content.

Written and compiled by Réal Gagnon ©1998-2005
[ home ]