IMDSPDevice3::SetProperty method (mswmdm.h)

The SetProperty method sets a specific device property that is writable.

Syntax

HRESULT SetProperty(
  [in] LPCWSTR           pwszPropName,
  [in] const PROPVARIANT *pValue
);

Parameters

[in] pwszPropName

Name of device property being set.

[in] pValue

Value of device property being set.

Return value

The method returns an HRESULT. All the interface methods in Windows Media Device Manager can return any of the following classes of error codes:

  • Standard COM error codes
  • Windows error codes converted to HRESULT values
  • Windows Media Device Manager error codes
For an extensive list of possible error codes, see Error Codes.

Remarks

This method sets the specified device property.

For a list of device property names, see Metadata Constants.

This method is similar to the SetMetadata method for storages, but this method can set only one property at a time.

Requirements

Requirement Value
Target Platform Windows
Header mswmdm.h
Library Mssachlp.lib

See also

IMDSPDevice3 Interface

IMDSPDevice3::GetProperty

IMDSPStorage3::SetMetadata

IMDSPStorage4::GetSpecifiedMetadata

Metadata Constants