Importance Property (Message Object)
Importance Property (Message Object)
The Importance property returns or sets the importance of the message. Read/write.
Syntax
objMessage.Importance
Data Type
Long
Remarks
The Importance property can have exactly one of the following values:
Constant |
Value |
Description |
CdoLow |
0 |
Low importance |
CdoNormal |
1 |
Normal importance (default) |
CdoHigh |
2 |
High importance |
AppointmentItem objects in a Microsoft® Schedule+ calendar folder do not have the full set of attributes of a general message. If you obtain the default calendar folder by passing CdoDefaultFolderCalendar to the Session object's GetDefaultFolder method, its appointments have no defined value for the Importance property. An attempt to access Importance in this case returns CdoE_NOT_FOUND.
The Importance property corresponds to the MAPI property PR_IMPORTANCE. It can be rendered into HTML hypertext using the CDO Rendering ObjectRenderer object. To specify this, set the object renderer's DataSource property to this Message object and the property parameter of the RenderProperty method to CdoPR_IMPORTANCE.
Example
This code fragment sets the importance of a message as high:
' from the sample function QuickStart:
Set objMessage = objSession.Outbox.Messages.Add
' ... check here to verify the message was created ...
objMessage.Subject = "Meeting change"
objMessage.Text = "Reschedule to Wednesday at noon."
objMessage.Importance = CdoHigh
objMessage.Send