Excludes

The Excludes element performs a bitwise mask of the specified property and a supplied value.

<Excludes>
   <FieldURI/>
   <Bitmask/>
</Excludes>
<Excludes>
   <ExtendedFieldURI/> 
   <Bitmask/>
</Excludes>
<Excludes>
   <IndexedFieldURI/> 
   <Bitmask/>
</Excludes>

ExcludesType

Attributes and elements

The following sections describe attributes, child elements, and parent elements.

Attributes

None.

Child elements

Element Description
FieldURI
Identifies frequently referenced properties by URI.
IndexedFieldURI
Identifies individual members of a dictionary.
ExtendedFieldURI
Identifies MAPI properties.
Bitmask
Represents a hexadecimal or decimal mask to be used during an Excludes restriction operation. If the bitmask represents a hexadecimal number, it must be prefixed by 0x or 0X. Otherwise, it will be considered a decimal number.

Parent elements

Element Description
Restriction
Represents the restriction or query that is used to filter items or folders in FindItem/FindFolder and search folder operations.
Not
Represents a search expression that negates the Boolean value of the search expression that it contains.
And
Represents a search expression that allows you to perform a Boolean And operation between two or more search expressions. The result of the And operation is true if all of the search expressions contained within the And are true.
Or
Represents a search expression that performs a logical OR on the search expression it contains. The Or element will return true if any of its children return true.

Remarks

Excludes will resolve to true if an AND operation performed on the following resolves to 0:

  1. The bitwise value for the property

  2. The bitmask value for the property

Excludes can only be applied to a property that has an integer value. If the property type is anything other than an integer, an error code of ErrorUnsupportedPathForQuery is returned in the response.

You can perform the reverse operation by calling Not(Excludes).

The schema that describes this element is located in the EWS virtual directory of the computer that is running Microsoft Exchange Server 2007 that has the Client Access server role installed.

Element information

Element Example
Namespace
https://schemas.microsoft.com/exchange/services/2006/types
Schema Name
Types schema
Validation File
Types.xsd
Can be Empty
False

See also