ISyncMgrSyncItem::Enable method (syncmgr.h)

Enables or disables the sync item.

Syntax

HRESULT Enable(
  [in] BOOL fEnable
);

Parameters

[in] fEnable

Type: BOOL

TRUE to enable; FALSE to disable.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

Sync Center calls this method in the following scenarios.

If the handler does not need to perform any actions when it is activated, it can return either S_OK or E_NOTIMPL as shown in the example below.

Examples

The following example shows a simple implementation of this method.

STDMETHODIMP CMyDeviceSyncItem::Enable(__in BOOL fEnable)
{
    return E_NOTIMPL;
}

Requirements

Requirement Value
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2008 [desktop apps only]
Target Platform Windows
Header syncmgr.h