HrGetOneProp

Send Feedback

The HrGetOneProp function retrieves the value of a single property from an object that support properties, such as an e-mail attachment, a MAPI container, a MAPI folder, a message, or a message store.

Note   This function may be deprecated in future versions of MAPI.

Syntax

HRESULT HrGetOneProp(
  LPMAPIPROP lpMapiProp
  ULONG ulPropTag
  LPSPropValue FAR * lppProp
);

Parameter

  • lpMapiProp
    [in] Reference to the object from which the property value is to be retrieved—which implements the IMAPIProp interface.
  • ulPropTag
    [in] Property tag of the property to be retrieved.
  • lppProp
    [out] Pointer to a pointer to the returned SPropValue structure defining the retrieved property value.

Return Values

This function returns an appropriate HRESULT value, such as the following:

  • S_OK
    The function successfully returned the value of a single property.
  • MAPI_E_NOT_FOUND
    The requested property cannot be found on the target object.

Remarks

Unlike the IMAPIProp::GetProps method, HrGetOneProp never returns a warning. Because it retrieves only one property, it either succeeds or fails. For retrieving multiple properties, use IMAPIProp::GetProps.

You can set or change a single property with the HrSetOneProp function.

Requirements

Pocket PC: Windows Mobile Version 5.0 and later
Smartphone: Windows Mobile Version 5.0 and later
OS Versions: Windows CE 5.01 and later
Header: mapiutil.h
Library: cemapi.lib

See Also

MAPI Functions | Messaging | MAPI Properties | HrSetOneProp | IMAPIProp::GetProps

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.