Skip to content

Commit ae8e059

Browse files
committed
mapi: add page for SCountRestriction
1 parent 2733340 commit ae8e059

2 files changed

Lines changed: 55 additions & 0 deletions

File tree

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
---
2+
title: "SCountRestriction"
3+
manager: lindalu
4+
ms.date: 12/27/2024
5+
ms.audience: Developer
6+
ms.topic: reference
7+
ms.service: office-online-server
8+
ms.localizationpriority: medium
9+
api_name:
10+
- MAPI.SCountRestriction
11+
api_type:
12+
- COM
13+
ms.assetid: d8961786-1686-4a90-b18e-ed56325fdb82
14+
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+
typedef struct _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).
50+
51+
## See also
52+
53+
[SRestriction](srestriction.md)
54+
[MAPI Structures](mapi-structures.md)

docs/outlook/mapi/types-of-restrictions.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ Each of the specialized restriction structures in the union represents a differe
3939
|Exist |[SExistRestriction](sexistrestriction.md) |Tests whether an object has a value for a property. |
4040
|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. |
4141
|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. |
4243

4344
Some restrictions use regular expressions, and MAPI supports a limited form of regular expression notation in the style that is used many text applications.
4445

0 commit comments

Comments
 (0)