RpcNsGroupMbrInqNextW function (rpcnsi.h)
The RpcNsGroupMbrInqNext function returns one entry name from a group at a time.
Syntax
RPC_STATUS RpcNsGroupMbrInqNextW(
RPC_NS_HANDLE InquiryContext,
RPC_WSTR *MemberName
);
Parameters
InquiryContext
Name service handle.
MemberName
Returns the address of a pointer to an RPC group member name. The syntax of the returned name was specified by the MemberNameSyntax parameter in the RpcNsGroupMbrInqBegin function.
Specify a null value to prevent RpcNsGroupMbrInqNext from returning the MemberName parameter. In this case, the application does not call the RpcStringFree function.
Return value
Value | Meaning |
---|---|
|
The call succeeded. |
|
The name-service handle is invalid. |
|
No more members. |
|
The name service is unavailable. |
Remarks
The RpcNsGroupMbrInqNext function returns one member of the RPC group specified by the GroupName parameter in RpcNsGroupMbrInqBegin. An application can view all the members of an RPC group set by repeatedly calling RpcNsGroupMbrInqNext. When all the group members have been viewed, this function 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 RpcStringFree for each returned MemberName string. After viewing the RPC group's members, the application must call RpcNsGroupMbrInqDone 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.
Note
The rpcnsi.h header defines RpcNsGroupMbrInqNext as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 2000 Professional [desktop apps only] |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | rpcnsi.h (include Rpc.h) |
Library | Rpcns4.lib |
DLL | Rpcns4.dll |