IsConflict Property

Microsoft Outlook Visual Basic

IsConflict Property

       

Returns a Boolean that determines if the item is in conflict. Whether or not an item is in conflict is determined by the state of the application. For example, when a user is offline and tries to access an online folder the action will fail. In this scenario, the IsConflict property will return True. Read-only.

expression.IsConflict

expression   Required. An expression that returns one of the objects in the Applies To list.

Remarks

If True, the specified item is in conflict.

Example

The following example creates a new message and attempts to send it. If the IsConflict property returns True, the item will not be sent.

Sub NewMail()
'Creates and attempts to send a new e-mail message

    Dim olApp As Outlook.Application
    Dim objNewMail As MailItem

    Set olApp = Outlook.Application
    Set objNewMail = olApp.CreateItem(olMailItem)
    objNewMail.Body = "This e-mail message was created automatically on " & Now
    objNewMail.To = "Jeff Smith"

    If objNewMail.IsConflict = False Then
        objNewMail.Send
    Else
        MsgBox "Conflict: Cannot send e-mail"
    End If

End Sub