UserProperties Property
This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.
Returns the UserProperties collection that represents all the user properties for the Outlook item.
expression**.UserProperties**
expression Required. An expression that returns one of the objects in the Applies To list.
Example
This VBScript example uses the CustomPropertyChange event to enable a control when a Boolean field is set to True.
For this example, create two custom fields on the second page of a form. The first, a Boolean field is named "RespondBy". The second field is named "DateToRespond".
Sub Item_CustomPropertyChange(ByVal myPropName)
Select Case myPropName
Case "RespondBy"
Set myPages = Item.GetInspector.ModifiedFormPages
Set myCtrl = myPages("P.2").Controls("DateToRespond")
If Item.UserProperties("RespondBy").Value Then
myCtrl.Enabled = True
myCtrl.Backcolor = 65535 'Yellow
Else
myCtrl.Enabled = False
myCtrl.Backcolor = 0 'Black
End If
Case Else
End Select
End Sub