IWindowsMediaLibrarySharingServices::setAuthorizationState method

The setAuthorizationState method enables or disables access to the current user's media library by a specified device.

Syntax


HRESULT setAuthorizationState(
  [in] BSTR         MACAddress,
  [in] VARIANT_BOOL authorizationState
);

Parameters

MACAddress [in]

A BSTR that specifies the MAC address of the device for which access will be enabled or disabled.

authorizationState [in]

A VARIANT_BOOL that specifies whether access by the device is enabled (VARIANT_TRUE) or disabled (VARIANT_FALSE).

Return value

The method returns an HRESULT. Possible values include, but are not limited to, those in the following table.

Return codeDescription
S_OK

The method succeeded.

 

Requirements

Minimum supported client

Windows 7 [desktop apps only]

Minimum supported server

Windows Server 2008 R2 [desktop apps only]

Header

Wmlss.h (include Wmlss.h)

DLL

WMPMediaSharing.dll

See also

IWindowsMediaLibrarySharingServices
IWindowsMediaLibrarySharingServices::setDefaultAuthorization

 

 

Community Additions

ADD
Show: