You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description: "Describes a count restriction, which is used to limit the number of times an (inner) restriction is evaluated."
15
+
---
16
+
17
+
# SCountRestriction
18
+
19
+
**Applies to**: Outlook 2013 | Outlook 2016
20
+
21
+
Describes a count restriction, which is used to limit the number of times an (inner) restriction is evaluated.
22
+
23
+
|Property |Value |
24
+
|:-----|:-----|
25
+
|Header file: <br/> |Mapidefs.h <br/> |
26
+
27
+
```cpp
28
+
typedefstruct_SCountRestriction
29
+
{
30
+
ULONG ulCount;
31
+
LPSRestriction lpRes;
32
+
} SCountRestriction;
33
+
```
34
+
35
+
## Members
36
+
37
+
**ulCount**
38
+
39
+
> When the restriction is evaluated, it shall match at most this many times.
40
+
41
+
**lpRes**
42
+
43
+
> Pointer to an [SRestriction](srestriction.md) structure.
44
+
45
+
## Remarks
46
+
47
+
If an implementation does not support count restrictions, it returns MAPI_E_TOO_COMPLEX from its [IMAPITable::Restrict](imapitable-restrict.md) or [IMAPITable::FindRow](imapitable-findrow.md) methods.
48
+
49
+
For a general discussion of how restrictions work, see [About Restrictions](about-restrictions.md).
|Property <br/> |[SPropertyRestriction](spropertyrestriction.md) <br/> |Specifies a particular property value as criteria for matching. Can be used, for example, to search for a particular type of attachment. |
37
-
|Bitmask <br/> |[SBitMaskRestriction](sbitmaskrestriction.md) <br/> |Applies a bitmask to a PT_LONG property, typically to determine whether particular flags are set. |
38
-
|Size <br/> |[SSizeRestriction](ssizerestriction.md) <br/> |Tests the size of a property using standard relational operators. |
39
-
|Exist <br/> |[SExistRestriction](sexistrestriction.md) <br/> |Tests whether an object has a value for a property. |
40
-
|Subobject <br/> |[SSubRestriction](ssubrestriction.md) <br/> |Used for searching through subobjects, or objects that cannot be accessed with an entry identifier, such as recipients and attachments. Can be used, for example, to look for messages for a particular recipient. |
41
-
|Comment <br/> |[SCommentRestriction](scommentrestriction.md) <br/> |Associates an object with a set of named properties. |
31
+
|Compare property |[SComparePropsRestriction](scomparepropsrestriction.md)|Compares two properties of the same type. |
32
+
|**AND**|[SAndRestriction](sandrestriction.md)|Performs a logical **AND** operation on two or more restrictions. |
33
+
|**OR**|[SOrRestriction](sorrestriction.md)|Performs a logical **OR** operation on two or more restrictions. |
34
+
|**NOT**|[SNotRestriction](snotrestriction.md)|Performs a logical **NOT** operation on two or more restrictions. |
|Property |[SPropertyRestriction](spropertyrestriction.md)|Specifies a particular property value as criteria for matching. Can be used, for example, to search for a particular type of attachment. |
37
+
|Bitmask |[SBitMaskRestriction](sbitmaskrestriction.md)|Applies a bitmask to a PT_LONG property, typically to determine whether particular flags are set. |
38
+
|Size |[SSizeRestriction](ssizerestriction.md)|Tests the size of a property using standard relational operators. |
39
+
|Exist |[SExistRestriction](sexistrestriction.md)|Tests whether an object has a value for a property. |
40
+
|Subobject |[SSubRestriction](ssubrestriction.md)|Used for searching through subobjects, or objects that cannot be accessed with an entry identifier, such as recipients and attachments. Can be used, for example, to look for messages for a particular recipient. |
41
+
|Comment |[SCommentRestriction](scommentrestriction.md)|Associates an object with a set of named properties. |
42
+
|Count |[SCountRestriction](scountrestriction.md)|Used for limiting results returned from evaluation of another restriction. |
42
43
43
44
Some restrictions use regular expressions, and MAPI supports a limited form of regular expression notation in the style that is used many text applications.
0 commit comments