Help / WLanguage / WLanguage functions / Communication / WiFi functions
  • Required permissions
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Stored procedures
Connects the device to the specified Wi-Fi network.
AndroidAndroid Widget Remarks:
  • The Wi-Fi access is not available in the Android emulator.
  • Starting with Android 6, it is no longer possible to connect to a network that has not been added by the application itself.
  • Caution: Starting with Android 10, it is no longer possible to connect to a Wi-Fi network through programming. This function causes a fatal error.
IF WiFiConnect("14758") = True THEN
Info("Wi-Fi connection established.")
<Result> = WiFiConnect(<Identifier> [, <Password>])
<Result>: Boolean
  • True if the connection was established,
  • False otherwise. ErrorInfo returns more information on the error.
<Identifier>: Character string
Identifier of the network to which we want to connect. This identifier can be:
  • the identifier returned by WiFiAddNetwork (for a network that was just added).
  • AndroidAndroid Widget the identifier of a network selected in the list of available networks (WiFiListNetwork).
    Caution: From Android 6, this type of identifier is no longer available..
<Password>: Optional character string
Password used to connect to a secured network. If this parameter is not specified, the password used will be the one saved in the network configuration (if this password exists).
AndroidAndroid Widget

Required permissions

The call to this function modifies the permissions required by the application.
Required permissions:
  • ACCESS_WIFI_STATE: this permission allows the applications to access information regarding the Wi-Fi networks.
  • CHANGE_WIFI_STATE: this permission allows the applications to modify the Wi-Fi connectivity status.
Related Examples:
WM System Cross-platform examples (WINDEV Mobile): WM System
[ + ] This application is an example of some of the features of WINDEV Mobile available for Android/iOS.
The following system functions are used:
- Multimedia control
- Brightness
- Volume
- Wi-Fi
- Bluetooth
- Toast
- Compass
- Accelerometer
- Camera control
- Vibration
- Notifications
- Drawing functions
- Internet
Component: wd280com.dll
Minimum version required
  • Version 16
This page is also available for…
Click [Add] to post a comment

Last update: 06/22/2023

Send a report | Local help