Share via


WlanSetProfileList (Compact 7)

3/12/2014

This function sets the preference order of profiles for a given interface.

Syntax

DWORD WINAPI WlanSetProfileList(
  __in        HANDLE hClientHandle,
  __in        const GUID* pInterfaceGuid,
  __in        DWORD dwItems,
  __in        LPCWSTR* strProfileNames,
  __reserved  PVOID pReserved 
);

Parameters

  • hClientHandle
    [in] Handle to the session on the client. To obtain a handle, call the WlanOpenHandle function.
  • pInterfaceGuid
    [in] GUID of the interface.
  • dwItems
    [in] Number of profiles in the strProfileNames parameter.
  • strProfileNames
    [in] Names of the profiles in the desired order. Profile names are case sensitive and the string must be NULL terminated.
  • pReserved
    Reserved; set to NULL.

Return Values

Value Description

ERROR_SUCCESS

The function succeeds.

ERROR_ACCESS_DENIED

You included Connection Manager in your OS.

The caller does not have sufficient permissions to change the profile list.

ERROR_INVALID_HANDLE

The handle hClientHandle was not found in the handle table.

ERROR_INVALID_PARAMETER

One of the following conditions occurred:

  • hClientHandle is NULL or invalid
  • pInterfaceGuid is NULL
  • dwItems is 0
  • strProfileNames is NULL
  • The same profile name appears multiple times in strProfileNames
  • pReserved is not NULL

ERROR_NOT_FOUND

strProfileNames contains the name of a profile that is not present in the profile store.

RPC_STATUS

Can be any remote procedure call (RPC) error code. The RPC call may be unsuccessful due to WLAN RPC server issues, such as when the RPC server is not started. Refer to RPC for more information.

Remarks

If you include Connection Manager in your OS design:

See Also

Reference

Native Wi-Fi Functions
WlanOpenHandle
WlanGetProfileList
Native Wi-Fi Reference