The RpcNsGroupMbrInqNext function returns one entry name from a group at a time.
#include <rpc.h>
RPC_STATUS RPC_ENTRY RpcNsGroupMbrInqNext(
RPC_NS_HANDLE InquiryContext,
unsigned char * * MemberName
);
The syntax of the returned name was specified by the MemberNameSyntax argument in the RpcNsGroupMbrInqBegin routine.
Specify a null value to prevent RpcNsGroupMbrInqNext from returning the MemberName argument. In this case, the application does not call the RpcStringFree routine.
Value | Meaning |
---|---|
RPC_S_OK | Success |
RPC_S_INVALID_NS_HANDLE | Invalid name-service handle |
RPC_S_NO_MORE_MEMBERS | No more members |
RPC_S_NAME_SERVICE_UNAVAILABLE | Name service unavailable |
Note The Windows NT 5.0 Active Directory Service supports this function. Support is not available from the Microsoft Locator in earlier versions of NT.
The RpcNsGroupMbrInqNext routine returns one member of the RPC group specified by the GroupName argument in the RpcNsGroupMbrInqBegin routine.
An application can view all the members of an RPC group set by repeatedly calling the RpcNsGroupMbrInqNext routine. When all the group members have been viewed, this routine returns an RPC_S_NO_MORE_MEMBERS status code. The returned group members are unordered.
On each call to RpcNsGroupMbrInqNext that returns a member name, the RPC run-time library allocates memory for the returned MemberName. The application is responsible for calling the RpcStringFree routine for each returned MemberName string.
After viewing the RPC group's members, the application must call the RpcNsGroupMbrInqDone routine to release the inquiry context.
The order in which group members are returned can be different for each viewing of a group. This means that the order in which group members are returned to an application can be different each time the application is run.
Windows NT: Yes
Windows CE: Unsupported.
Header: Declared in rpcnsi.h.
Import Library: Link with rpcns4.lib.
RpcNsGroupMbrInqBegin, RpcNsGroupMbrInqDone, RpcStringFree