Events
Nov 19, 11 PM - Nov 21, 11 PM
Gain the competitive edge you need with powerful AI and Cloud solutions by attending Microsoft Ignite online.
Register nowThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
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 specific connection profile associated with the given Mobile Broadband device.
HRESULT GetConnectionProfile(
[in] IMbnInterface *mbnInterface,
[in] LPCWSTR profileName,
[out, retval] IMbnConnectionProfile **connectionProfile
);
[in] mbnInterface
An IMbnInterface that represents the device for which the profile request applies. If mbnInterface is NULL, then this function will return the profile of the given name associated with any device in the system.
[in] profileName
A null-terminated string that contains the name of the connection profile.
[out, retval] connectionProfile
An IMbnConnectionProfile interface that represents the desired connection profile. If this method returns anything other than S_OK, this is NULL.
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. |
|
A profile with the given name does not exist. |
|
The device is not ready. Unable to obtain the subscriber ID because the device is not MBN_READY_STATE_INITIALIZED. |
|
A profile with the given name does not exist. |
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.
If a new profile has been created using CreateConnectionProfile, then the caller must wait for the OnConnectionProfileArrival event to be received before calling GetConnectionProfile with the new profile's name; otherwise, the GetConnectionProfile API call may fail with HRESULT_FROM_WIN32(ERROR_NOT_FOUND).
Requirement | Value |
---|---|
Minimum supported client | Windows 7 [desktop apps only] |
Minimum supported server | None supported |
Target Platform | Windows |
Header | mbnapi.h |
Events
Nov 19, 11 PM - Nov 21, 11 PM
Gain the competitive edge you need with powerful AI and Cloud solutions by attending Microsoft Ignite online.
Register now