This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
Describes a property restriction which is used to match a constant with the value of a property.
There are two property tags in a SPropertyRestriction structure. One is in the ulPropTag member and the other is in the ulPropTag member of the SPropValue structure pointed to by lpProp. In both tags, MAPI requires only the property type field and ignores the property identifier field. However, the two property types must match, or else the error value MAPI_E_TOO_COMPLEX is returned when the restriction is used in a call to IMAPITable::Restrict or IMAPITable::FindRow.
The comparison order is (property value) (relational operator) (constant value).
When a property restriction is passed to IMAPITable::Restrict or IMAPITable::FindRow and the target property does not exist, the results of the restriction are undefined. By creating an AND restriction that joins the property restriction with an exist restriction, a caller can be guaranteed accurate results. Use a SExistRestriction structure to define the exist restriction and a SAndRestriction structure to define the AND restriction.
Multi-valued property tags can be used in property restrictions if the service provider implementing the table supports them. If supported, multi-valued property tags can be used anywhere single-valued property tags can be used.
Multi-valued property tags can be used in the following methods:
For more information about the SPropertyRestriction structure, see About Restrictions.