This documentation is archived and is not being maintained.

MsgBox Style Constant Changes in Visual Basic .NET

The following table shows the Visual Basic 6.0 MsgBox Style constants and their Visual Basic .NET equivalents.

Note   For backward compatibility, the Visual Basic 6.0 MsgBox Style constants may also be used in Visual Basic .NET.
Visual Basic 6.0Visual Basic .NET Equivalent
vbOKOnlyMsgBoxStyle.OKOnly
vbOKCancelMsgBoxStyle.OKCancel
vbAbortRetryIgnoreMsgBoxStyle.AbortRetryIgnore
vbYesNoCancelMsgBoxStyle.YesNoCancel
vbYesNoMsgBoxStyle.YesNo
vbRetryCancelMsgBoxStyle.RetryCancel
vbCriticalMsgBoxStyle.Critical
vbQuestionMsgBoxStyle.Question
vbExclamationMsgBoxStyle.Exclamation
vbInformationMsgBoxStyle.Information
vbDefaultButton1MsgBoxStyle.DefaultButton1
vbDefaultButton2MsgBoxStyle.DefaultButton2
vbDefaultButton3MsgBoxStyle.DefaultButton3
vbDefaultButton4No equivalent
vbApplicationModalMsgBoxStyle.ApplicationModal
vbSystemModalMsgBoxStyle.SystemModal
vbMsgBoxHelpButtonMsgBoxStyle.MsgBoxHelp
vbMsgBoxRightMsgBoxStyle.MsgBoxRight
vbMsgBoxRtlReadingMsgBoxStyle.MsgBoxRtlReading
vbMsgBoxSetForegroundMsgBoxStyle.MsgBoxSetForeground

See Also

Constant Changes in Visual Basic .NET | MsgBoxStyle Enumeration | Constants and Enumerations

Show: