ebCancel (constant)

Description Returned by the MsgBox function when the Cancel button is chosen.
Comments This constant is equal to 2.
Example
Sub Main()
  'Invoke MsgBox and check whether the Cancel button was pressed.
  rc% = MsgBox("Are you sure you want to quit?",ebOKCancel)
  If rc% = ebCancel Then
    MsgBox "The user clicked Cancel."
  End If
End Sub
See Also MsgBox (function); MsgBox (statement).