IMbnSms::SetSmsConfiguration 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.

Updates the SMS configuration for a device.

Syntax

HRESULT SetSmsConfiguration(
  [in]  IMbnSmsConfiguration *smsConfiguration,
  [out] ULONG                *requestID
);

Parameters

[in] smsConfiguration

An IMbnSmsConfiguration interface representing the new SMS configuration to update the device with.

[out] requestID

A pointer to a request ID issued by the Mobile Broadband service to identify this request.

Return value

This method can return one of these values.

Return code Description
S_OK
The method completed successfully.
HRESULT_FROM_WIN32(ERROR_SERVICE_NOT_ACTIVE)
The Mobile Broadband service is not running on the system.
E_HANDLE
The interface is invalid, most likely because the device was removed from the system.
HRESULT_FROM_WIN32(ERROR_NOT_FOUND)
The interface is invalid. Most likely the Mobile Broadband device has been removed from the system.

Remarks

An application can use SetSmsConfiguration to modify the default SMS Service Center address in the device.

An application should perform following steps for setting SMS configuration of the device.

  1. Get an IMbnSmsConfiguration interface by calling GetSmsConfiguration.
  2. Modify the IMbnSmsConfiguration interface obtained from step 1 with the new values that reflect the desired changes to the configuration..
  3. Pass the modified IMbnSmsConfiguration to SetSmsConfiguration.
This is an asynchronous operation that will return immediately. If the method returns without error, then the Mobile Broadband service will call the OnSetSmsConfigurationComplete method of the IMbnSmsEvents interface.

Requirements

Requirement Value
Minimum supported client Windows 7 [desktop apps only]
Minimum supported server None supported
Target Platform Windows
Header mbnapi.h

See also

IMbnSms

IMbnSmsConfiguration