Using Win32 functions in Visual FoxPro Image Gallery
Code examples:
Determining if an Active Network Connection is Available
Retrieving list of all active RAS connections
Simple MAPI: how to resolve a name to unique address list entry
List of ODBC drivers installed (read from the [ODBC Drivers] section)
Retrieving country-specific dialing information from the Windows Telephony list of countries
Retrieving the name and type of all available RAS-capable devices
Pocket PC: retrieving data from the Contacts Database
Pocket PC: enumerating mounted database volumes and databases in the Object Store
Setting the Window Region for a form
GDI+: custom control, base class
Searching for the specified file using the SearchPath
Using Video Capture: enumerating installed capture drivers
Accessing a CD device (cdaudio) with Multimedia Command Strings
How to perform Base64 encoding/decoding using Cryptography API Functions
Pocket PC: System Registry Viewer
PocketPC: creating directories and files
Testing Transparent Menu Class with top-level form (requires VFP9)
Retrieving the path of the printer-driver directory and printer-processor directory
WAV file recorder
How to intercept window messages sent to VFP form
Pocket PC: creating backup for the System Registry
Using Custom FTP class (DEFINE CLASS ftp As Custom)
Terminating VFP application using the FatalAppExit
Creating ESE database and table
Determining if an Active Network Connection is Available

User rating: 0/10 (0 votes)
Rate this code sample:
  • ~
More code examples    Listed functions    Add comment     W32 Constants      Translate this page Printer friendly version of this code sample
#DEFINE NETWORK_ALIVE_LAN 1
#DEFINE NETWORK_ALIVE_WAN 2
#DEFINE NETWORK_ALIVE_AOL 4

DECLARE INTEGER IsNetworkAlive IN sensapi INTEGER @lpdwFlags
DECLARE INTEGER GetLastError IN kernel32

LOCAL lnMode
lnMode = 0
IF IsNetworkAlive(@lnMode) = 0
    ? "Error code: ", GetLastError()
ELSE
    ? "The computer has one or more LAN cards that are active:",;
        (lnMode=NETWORK_ALIVE_LAN)

    ? "The computer has one or more active RAS connections:",;
        (lnMode=NETWORK_ALIVE_WAN)

    * Win95, Win98 only
    ? "The computer is connected to the America Online network:",;
        (lnMode=NETWORK_ALIVE_AOL)
ENDIF


User rating: 0/10 (0 votes)
Rate this code sample:
  • ~
607 bytes  
Created: 2002-08-10 12:03:15  
Modified: 2002-08-10 12:04:56  
Visits in 7 days: 28  
Listed functions:
GetLastError
IsNetworkAlive
Printer friendly API declarations
My comment:
Check similar VB example "Determining if an Active Network Connection is Available" at the VBNet.
Word Index links for this example:
Translate this page:
  Spanish    Portuguese    German    French    Italian  
FreeTranslation.com offers instant, free translations of text or web pages.
User Contributed Notes:
There are no notes on this subject.


Copyright 2001-2018 News2News, Inc. Before reproducing or distributing any data from this site please ask for an approval from its owner. Unless otherwise specified, this page is for your personal and non-commercial use. The information on this page is presented AS IS, meaning that you may use it at your own risk. Microsoft Visual FoxPro and Windows are trade marks of Microsoft Corp. All other trademarks are the property of their respective owners. 

Privacy policy
Credits: PHP (4.4.9), an HTML-embedded scripting language, MySQL (5.6.39), the Open Source standard SQL database, AceHTML Freeware Version 4, freeware HTML Editor of choice.   Hosted by Korax Online Inc.
Last Topics Visited (54.226.33.117)
23 sec.Function: 'CeRegEnumValue'
Function group: 'Remote Application Programming (RAPI)'
43 sec.Example: 'Adding supplementary data to AVI files'
1.05 min.Function: 'InternetTimeFromSystemTime'
1.4 min.Function: 'NetUserEnum'
Function group: 'Network Management'
1.73 min.Function: 'CeDeleteRecord'
Function group: 'Remote Application Programming (RAPI)'
2.1 min.Function: 'CeRemoveDirectory'
Function group: 'Remote Application Programming (RAPI)'
2.45 min.Function: 'CryptDecrypt'
Function group: 'Cryptography Reference'
3.13 min.Example: 'Tracking mouse movement to detect when to start dragging'
3.5 min.Function: 'FreePrinterNotifyInfo'
Function group: 'Printing and Print Spooler'
3.83 min.Function: 'GetProcessTimes'
Function group: 'Process and Thread'
Google
Advertise here!