ItemProperty.Value property (Outlook)
Returns or sets a Variant indicating the value for the specified custom or explicit built-in property. Read/write.
Syntax
expression.Value
expression A variable that represents an ItemProperty object.
Remarks
Even though ItemProperty.Value allows you to get or set an explicit built-in property or a custom property, you can reference explicit built-in properties directly from the parent object, for example, ContactItem.Body
. For more information on accessing properties in Outlook, see Properties Overview.
Example
The following Visual Basic for Applications (VBA) example creates a contact item and sets its Body property
Sub ValueItemProperty()
Dim cti As Outlook.ContactItem
Dim itms As Outlook.ItemProperties
Dim itm As Outlook.ItemProperty
Set cti = Application.CreateItem(olContactItem)
cti.FullName = "Dan Wilson"
Set itms = cti.ItemProperties
Set itm = itms.Item("Body")
itm.Value = "My friend from school"
cti.Save
cti.Display
End Sub
See also
Support and feedback
Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.