wclWiFiClientConnect(Guid, wclWiFiConnectionMode, String, String, wclWiFiBssType, wclWiFiConnectFlag, String) Method |
The method attempts to connect to a specific
network.
Namespace: wclWiFiAssembly: wclWiFiFramework (in wclWiFiFramework.dll) Version: 7.13.1.0 (7.13.1.0)
Syntaxpublic int Connect(
Guid IfaceId,
wclWiFiConnectionMode Mode,
string Profile,
string Ssid,
wclWiFiBssType BssType,
wclWiFiConnectFlag Flags,
string Bss
)
Public Function Connect (
IfaceId As Guid,
Mode As wclWiFiConnectionMode,
Profile As String,
Ssid As String,
BssType As wclWiFiBssType,
Flags As wclWiFiConnectFlag,
Bss As String
) As Integer
public:
int Connect(
Guid IfaceId,
wclWiFiConnectionMode Mode,
String^ Profile,
String^ Ssid,
wclWiFiBssType BssType,
wclWiFiConnectFlag Flags,
String^ Bss
)
Parameters
- IfaceId Guid
- The ID of the interface to use for the
connection.
- Mode wclWiFiConnectionMode
- A value that specifies the mode of
connection.
- Profile String
Specifies the profile being used for the
connection.
If Mode is set to cmProfile, then Profile
specifies the name of the profile used for the connection.
If Mode is set to cmTemporaryProfile, then
Profile specifies the XML representation of the profile used
for the connection.
If Mode is set to cmDiscoverySecure
or cmDiscoveryUnsecure, then Profile should
be set to an empty string.
- Ssid String
- Specifies the SSID of the network to connect to.
This parameter is optional. When set to and empty string, all SSIDs
in the profile will be tried. This parameter must not be an empty
string if Mode is set to cmDiscoverySecure or
cmDiscoveryUnsecure.
- BssType wclWiFiBssType
- Indicates the BSS type of the network. If a
profile is provided, this BSS type must be the same as the one in the
profile.
- Flags wclWiFiConnectFlag
- The flags used to specify the connection
parameters.
- Bss String
- The basic service set (BSS) identifier (MAC) desired for
the connection.
Return Value
Int32 If the function succeeds, the return value is
WCL_E_SUCCESS.
If the function fails, the return value may be one of the WCL
return codes.
Remarks The Connect method returns immediately. To be
notified when a connection is established or when no further
connections will be attempted, a client must use the
wclWiFiEvents component.
See Also