PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • Required permissions
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
WiFiStatus (Function)
In French: WiFiEtat
Returns the current activation status of Wi-Fi on the device or asks to be notified when the activation status of Wi-Fi changes.
Notes:
  • AndroidAndroid Widget To enable or disable the Wi-Fi on the device, use WiFiActivate.
  • AndroidAndroid Widget The Wi-Fi access is not available in the Android emulator.
Versions 18 and later
Android Widget This function is now available in Android Widget mode.
New in version 18
Android Widget This function is now available in Android Widget mode.
Android Widget This function is now available in Android Widget mode.
Versions 19 and later
iPhone/iPad This function is now available for the iPhone/iPad applications.
WEBDEV - Browser code This function is now available in Browser code.
New in version 19
iPhone/iPad This function is now available for the iPhone/iPad applications.
WEBDEV - Browser code This function is now available in Browser code.
iPhone/iPad This function is now available for the iPhone/iPad applications.
WEBDEV - Browser code This function is now available in Browser code.
Example
IF WiFiStatus() = wifiDisabled THEN
        WiFiActivate(True)
END
Syntax

Finding out the current activation status of Wi-Fi on the current computer Hide the details

<Result> = WiFiStatus()
<Result>: Integer
Current activation status of Wi-Fi:
wifiEnabledThe Wi-Fi is enabled on the device.
wifiActivationInProgressThe Wi-Fi is being enabled on the device.
WEBDEV - Browser code This constant is not available.
wifiDisabledThe Wi-Fi is disabled on the device.
wifiDeactivationInProgressThe Wi-Fi is being disabled on the device.
WEBDEV - Browser code This constant is not available.
wifiErrorThe activation status of Wi-Fi cannot be retrieved.
iPhone/iPad This constant does not correspond to a possible option.
AndroidAndroid Widget

Enabling the notification for changes of Wi-Fi activation Hide the details

WiFiStatus(<Procedure Name>)
<Procedure Name>: Character string (with or without quotes)
WLanguage procedure ("callback" procedure) called when the activation status of Wi-Fi changes on the device.
This procedure has the following format :
PROCEDURE <Procedure Name> (<New Status>, <Former Status>)
where:
  • <New Status> is an integer corresponding ot the new activation status of Wi-Fi on the device
  • <Former Status> is an integer corresponding to the activation status of Wi-Fi on the device before the change of status.
The parameters of this procedure are optional. There is no need to pass parameters to this procedure. Indeed, these parameters are automatically filled during each call.
If this parameter corresponds to an empty string (""), the notifications will not be sent anymore when the status changes. The function has no effect if no notification request was performed.
Remarks
Android

Required permissions

The call to this function modifies the permissions required by the application.
Required permission : ACCESS_WIFI_STATE
This permission allows the applications to access information regarding the Wi-Fi networks.
Related Examples:
Android System Android (WINDEV Mobile): Android System
[ + ] This application is a tutorial example presenting some of the new features of WINDEV Mobile for Android.
The following system functions are used:
- NFC
- Multimedia control
- Brightness
- Volume
- WIFI
- Bluetooth
- Toast
- Progress Bar control
- 9-image mode
- Compass
- Accelerometer
- Camera control
- LED
- Vibrations
- Notifications
- Drawing functions
- Internet
Components
WEBDEV - Browser code WDJS.DLL
Android wd230android.jar
Minimum required version
  • Version 16
This page is also available for…
Comments
Click [Add] to post a comment