MsgBoxStyle Enumeration
This enumeration has a FlagsAttribute attribute that allows a bitwise combination of its member values.
Namespace: Microsoft.VisualBasicAssembly: Microsoft.VisualBasic (in microsoft.visualbasic.dll)
| Member name | Description | |
|---|---|---|
![]() | AbortRetryIgnore | Abort, Retry, and Ignore buttons. This member is equivalent to the Visual Basic constant vbAbortRetryIgnore. |
![]() | ApplicationModal | Application modal message box. This member is equivalent to the Visual Basic constant vbApplicationModal. |
![]() | Critical | Critical message. This member is equivalent to the Visual Basic constant vbCritical. |
![]() | DefaultButton1 | First button is default. This member is equivalent to the Visual Basic constant vbDefaultButton1. |
![]() | DefaultButton2 | Second button is default. This member is equivalent to the Visual Basic constant vbDefaultButton2. |
![]() | DefaultButton3 | Third button is default. This member is equivalent to the Visual Basic constant vbDefaultButton3. |
![]() | Exclamation | Warning message. This member is equivalent to the Visual Basic constant vbExclamation. |
![]() | Information | Information message. This member is equivalent to the Visual Basic constant vbInformation. |
![]() | MsgBoxHelp | Help text. This member is equivalent to the Visual Basic constant vbMsgBoxHelp. |
![]() | MsgBoxRight | Right-aligned text. This member is equivalent to the Visual Basic constant vbMsgBoxRight. |
![]() | MsgBoxRtlReading | Right-to-left reading text (Hebrew and Arabic systems). This member is equivalent to the Visual Basic constant vbMsgBoxRtlReading. |
![]() | MsgBoxSetForeground | Foreground message box window. This member is equivalent to the Visual Basic constant vbMsgBoxSetForeground. |
![]() | OkCancel | |
![]() | OKCancel | OK and Cancel buttons. This member is equivalent to the Visual Basic constant vbOKCancel. |
![]() | OkOnly | |
![]() | OKOnly | OK button only (default). This member is equivalent to the Visual Basic constant vbOKOnly. |
![]() | Question | Warning query. This member is equivalent to the Visual Basic constant vbQuestion. |
![]() | RetryCancel | Retry and Cancel buttons. This member is equivalent to the Visual Basic constant vbRetryCancel. |
![]() | SystemModal | System modal message box. This member is equivalent to the Visual Basic constant vbSystemModal. |
![]() | YesNo | Yes and No buttons. This member is equivalent to the Visual Basic constant vbYesNo. |
![]() | YesNoCancel | Yes, No, and Cancel buttons. This member is equivalent to the Visual Basic constant vbYesNoCancel. |
For more detailed information, see the Visual Basic topic MsgBoxStyle Enumeration.
When you call the MsgBox function, you can use the MsgBoxStyle enumeration in your code in place of the actual values. The Buttons argument takes the MsgBoxStyle enumeration members.
Windows 98, Windows 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see System Requirements.
