Επεξεργασία

Κοινή χρήση μέσω


AssocCreate function (shlwapi.h)

Returns a pointer to an IQueryAssociations object.

Syntax

LWSTDAPI AssocCreate(
  [in]  CLSID  clsid,
  [in]  REFIID riid,
  [out] void   **ppv
);

Parameters

[in] clsid

Type: CLSID

The CLSID of the object that exposes the interface. This parameter must be set to CLSID_QueryAssociations, which is defined in Shlguid.h.

[in] riid

Type: REFIID

Reference to the IID IID_IQueryAssociations, which is defined in Shlguid.h.

[out] ppv

Type: void*

When this method returns, contains the IQueryAssociations interface pointer requested in riid.

Return value

Type: HRESULT

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

Remarks

As of Windows Vista, AssocCreateForClasses is preferred to AssocCreate.

Requirements

Requirement Value
Minimum supported client Windows 2000 Professional, Windows XP [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header shlwapi.h
Library Shlwapi.lib
DLL Shlwapi.dll (version 5.0 or later)