IMbnConnectionProfileManager::GetConnectionProfiles method (mbnapi.h)
Important
Starting in Windows 10, version 1803, the Win32 APIs described in this section are replaced by the Windows Runtime APIs in the Windows.Networking.Connectivity namespace.
Gets a list of connection profiles associated with the device.
Syntax
HRESULT GetConnectionProfiles(
[in] IMbnInterface *mbnInterface,
[out, retval] SAFEARRAY **connectionProfiles
);
Parameters
[in] mbnInterface
An IMbnInterface that represents the device for which the profile request applies. If this is NULL, the function will return all of the profiles that are present in the system.
[out, retval] connectionProfiles
An array of IMbnConnectionProfile interfaces that represent all the available connection profiles for the device. If this method returns anything other than S_OK, the array pointer is NULL, otherwise the calling application must eventually free the allocated memory by calling SafeArrayDestroy.
Return value
This method can return one of these values.
Return code | Description |
---|---|
|
The method completed successfully. |
|
The interface is invalid, most likely because the Mobile Broadband device has been removed from the system. |
|
The device is not ready. Unable to obtain the subscriber ID because the device is not MBN_READY_STATE_INITIALIZED. |
|
The Mobile Broadband service is not running on this system. |
Remarks
When this operation is called for a particular device, it returns a list of profiles which have the same subscriber ID as currently reported by device. The GetSubscriberInformation method of IMbnInterface can be used to obtain the subscriber ID associated with the interface.
A connection profile is associated with the subscriber ID of the device. For GSM devices the subscriber ID is the International Mobile Subscriber Identity (IMSI) of the SIM. For CDMA devices it is the Mobile Identification Number (MIN) string or the International Roaming MIN (IRM) string.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 7 [desktop apps only] |
Minimum supported server | None supported |
Target Platform | Windows |
Header | mbnapi.h |