title | keywords | f1_keywords | api_name | ms.assetid | ms.date | ms.localizationpriority | ||
---|---|---|---|---|---|---|---|---|
ItemProperty.Value property (Outlook) |
vbaol11.chm527 |
|
|
81144bd5-15d5-a233-6001-f8c80392850f |
06/08/2017 |
medium |
Returns or sets a Variant indicating the value for the specified custom or explicit built-in property. Read/write.
expression.Value
expression A variable that represents an ItemProperty object.
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.
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
[!includeSupport and feedback]