WsGetPolicyAlternativeCount function (webservices.h)
Retrieves the number of alternatives available in the policy object. The alternative count can be used to loop through each alternative using WsMatchPolicyAlternative.
Syntax
HRESULT WsGetPolicyAlternativeCount(
[in] WS_POLICY *policy,
[out] ULONG *count,
[in, optional] WS_ERROR *error
);
Parameters
[in] policy
A pointer to the WS_POLICY object from which to count alternatives.
[out] count
A pointer to the number value of alternatives. This may be 0.
[in, optional] error
A pointer to a WS_ERROR object where additional information about the error should be stored if the function fails.
Return value
This function can return one of these values.
Return code | Description |
---|---|
|
The property id was not supported for this object or the specified buffer was not large enough for the value. |
|
Ran out of memory. |
|
This function may return other errors not listed above. |
Remarks
Note that each alternative is not guaranteed to be unique within the policy (there may be duplicates).
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 7 [desktop apps | UWP apps] |
Minimum supported server | Windows Server 2008 R2 [desktop apps | UWP apps] |
Target Platform | Windows |
Header | webservices.h |
Library | WebServices.lib |
DLL | WebServices.dll |
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for