MgmGroupEnumerationStart function (mgm.h)

The MgmGroupEnumerationStart function obtains an enumeration handle that is later used to obtain the list of groups that have been joined. After the client obtains the handle, it should use the MgmGroupEnumerationGetNext function to enumerate the groups.

Syntax

DWORD MgmGroupEnumerationStart(
  [in]  HANDLE         hProtocol,
  [in]  MGM_ENUM_TYPES metEnumType,
  [out] HANDLE         *phEnumHandle
);

Parameters

[in] hProtocol

Handle to the protocol obtained from a previous call to MgmRegisterMProtocol.

[in] metEnumType

Specifies the type of enumeration. The following enumerations are available.

Enumeration Meaning
ALL_SOURCES
Retrieves wildcard joins (*, g) and source-specific joins (s, g).
ANY_SOURCE
Retrieves group entries that have at least one source specified.

[out] phEnumHandle

Receives the handle to the enumeration. Use this handle in calls to MgmGroupEnumerationGetNext and MgmGroupEnumerationEnd.

Return value

If the function succeeds, the return value is NO_ERROR.

If the function fails, the return value is one of the following error codes.

Value Meaning
ERROR_CAN_NOT_COMPLETE
Could not complete the call to this function.
ERROR_INVALID_PARAMETER
Invalid handle to a protocol.
ERROR_NOT_ENOUGH_MEMORY
Not enough memory to complete this operation.
 
 

Requirements

   
Minimum supported client None supported
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header mgm.h
Library Rtm.lib
DLL Rtm.dll

See also

MGM_ENUM_TYPES

MgmGroupEnumerationEnd

MgmGroupEnumerationGetNext