This documentation is archived and is not being maintained.
MsgBoxStyle Enumeration
Visual Studio 2010
Indicates which buttons to display when calling the MsgBox function.
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 | |
|---|---|---|
| OkOnly | OK button only (default). This member is equivalent to the Visual Basic constant vbOKOnly. | |
| OkCancel | OK and Cancel buttons. This member is equivalent to the Visual Basic constant vbOKCancel. | |
| AbortRetryIgnore | Abort, Retry, and Ignore buttons. This member is equivalent to the Visual Basic constant vbAbortRetryIgnore. | |
| YesNoCancel | Yes, No, and Cancel buttons. This member is equivalent to the Visual Basic constant vbYesNoCancel. | |
| YesNo | Yes and No buttons. This member is equivalent to the Visual Basic constant vbYesNo. | |
| RetryCancel | Retry and Cancel buttons. This member is equivalent to the Visual Basic constant vbRetryCancel. | |
| Critical | Critical message. This member is equivalent to the Visual Basic constant vbCritical. | |
| Question | Warning query. This member is equivalent to the Visual Basic constant vbQuestion. | |
| 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. | |
| 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. | |
| ApplicationModal | Application modal message box. This member is equivalent to the Visual Basic constant vbApplicationModal. | |
| SystemModal | System modal message box. This member is equivalent to the Visual Basic constant vbSystemModal. | |
| 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. |
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Show: