Class MessageBoxAdv
Displays a message box with Office2007 style that can contain text, buttons, and symbols that inform and instruct the user.
Inheritance
Inherited Members
Namespace: Syncfusion.Windows.Forms
Assembly: Syncfusion.Shared.Base.dll
Syntax
public static class MessageBoxAdv
Properties
ApplyAeroTheme
Gets or sets whehter to apply AeroTheme in Default MessageBoxStyle.
Declaration
public static bool ApplyAeroTheme { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
ButtonFont
Gets or sets the Button option Font
Declaration
public static Font ButtonFont { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Font |
CanResize
Gets or sets value to determine whether MessageBoxAdv can be resized.
Declaration
public static bool CanResize { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
CaptionAlign
Specifies the title alignment of MessageBoxAdv.
Declaration
public static HorizontalAlignment CaptionAlign { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Windows.Forms.HorizontalAlignment | Default caption alignment is Left. |
Remarks
This property is not applicaple when enabling ApplyAeroTheme property in Default Style.
CaptionFont
Gets or sets the Caption Font
Declaration
public static Font CaptionFont { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Font |
DetailsFont
Gets or sets the Details Font
Declaration
public static Font DetailsFont { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Font |
DropShadow
Specifies the Shadow effect of the MessageBox.
Declaration
public static bool DropShadow { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
MaximumSize
Specifies the Maximum Size of MessageBoxAdv.
Declaration
public static Size MaximumSize { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Size |
MessageBoxStyle
Gets or sets a value indicating the style used for drawing the control
Declaration
public static MessageBoxAdv.Style MessageBoxStyle { get; set; }
Property Value
| Type |
|---|
| MessageBoxAdv.Style |
MessageFont
Gets or sets the Message Font
Declaration
public static Font MessageFont { get; set; }
Property Value
| Type |
|---|
| System.Drawing.Font |
MetroColorTable
Color table to customize the buttons,captions and text color in MessageBoxAdv
Declaration
public static MetroStyleColorTable MetroColorTable { get; set; }
Property Value
| Type |
|---|
| MetroStyleColorTable |
Office2007Theme
Gets or sets the Office2007 theme, which is used to show message boxes.
Declaration
public static Office2007Theme Office2007Theme { get; set; }
Property Value
| Type | Description |
|---|---|
| Office2007Theme | The Office2007 theme. |
Office2010Theme
Gets or sets the Office2010 color theme.
Declaration
public static Office2010Theme Office2010Theme { get; set; }
Property Value
| Type |
|---|
| Office2010Theme |
Office2013Theme
Gets or sets the Office2013 color theme.
Declaration
public static Office2013Theme Office2013Theme { get; set; }
Property Value
| Type |
|---|
| Office2013Theme |
Office2016Theme
Gets or sets the Office2016 color theme.
Declaration
public static Office2016Theme Office2016Theme { get; set; }
Property Value
| Type |
|---|
| Office2016Theme |
RightToLeft
Gets or sets a value indicating whether control's elements are aligned to Right-To-Left or Left-To-Right Layout
Declaration
public static RightToLeft RightToLeft { get; set; }
Property Value
| Type |
|---|
| System.Windows.Forms.RightToLeft |
ThemeName
Gets or sets the theme name of the control.
Declaration
public static string ThemeName { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String | The default value is null. |
Remarks
This ThemeStyle settings will be applied only when the VisualStyleBased theme has been applied to the control.
UseDefaultTheme
Specifies the default backcolor of the MessageBoxAdv.
Declaration
public static bool UseDefaultTheme { get; set; }
Property Value
| Type |
|---|
| System.Boolean |
Methods
Show(String)
Displays a message box with specified text.
Declaration
public static DialogResult Show(string text)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String)
Displays a message box with specified text and caption.
Declaration
public static DialogResult Show(string text, string caption)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, String)
Declaration
public static DialogResult Show(string text, string caption, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | |
| System.String | caption | |
| System.String | details |
Returns
| Type |
|---|
| System.Windows.Forms.DialogResult |
Show(String, String, String[])
To Show MessageBoxAdv
Declaration
public static int Show(string text, string caption, string[] buttons)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | MessageBoxAdv Text |
| System.String | caption | MessageBoxAdv Caption |
| System.String[] | buttons | Custom Buttons Collection |
Returns
| Type |
|---|
| System.Int32 |
Show(String, String, String[], Image, Size)
To Show MessageBoxAdv
Declaration
public static int Show(string text, string caption, string[] buttons, Image image, Size imageSize)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | MessageBoxAdv Text |
| System.String | caption | MessageBoxAdv Caption |
| System.String[] | buttons | Custom Buttons Collection |
| System.Drawing.Image | image | Image to be displayed in MessageBoxAdv |
| System.Drawing.Size | imageSize | Size of the Image |
Returns
| Type | Description |
|---|---|
| System.Int32 | Selected Button Index |
Show(String, String, String[], Image, Size, String)
Declaration
public static int Show(string text, string caption, string[] buttons, Image image, Size imageSize, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | |
| System.String | caption | |
| System.String[] | buttons | |
| System.Drawing.Image | image | |
| System.Drawing.Size | imageSize | |
| System.String | details |
Returns
| Type |
|---|
| System.Int32 |
Show(String, String, String[], String)
Declaration
public static int Show(string text, string caption, string[] buttons, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | |
| System.String | caption | |
| System.String[] | buttons | |
| System.String | details |
Returns
| Type |
|---|
| System.Int32 |
Show(String, String, String[], MessageBoxIcon)
To Show MessageBoxAdv
Declaration
public static int Show(string text, string caption, string[] buttons, MessageBoxIcon icon)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | MessageBoxAdv Text |
| System.String | caption | MessageBoxAdv Caption |
| System.String[] | buttons | Custom Buttons Collection |
| System.Windows.Forms.MessageBoxIcon | icon | Icon to be displayed in MessageBoxAdv |
Returns
| Type | Description |
|---|---|
| System.Int32 | Selected Button Index |
Show(String, String, String[], MessageBoxIcon, String)
Declaration
public static int Show(string text, string caption, string[] buttons, MessageBoxIcon icon, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | |
| System.String | caption | |
| System.String[] | buttons | |
| System.Windows.Forms.MessageBoxIcon | icon | |
| System.String | details |
Returns
| Type |
|---|
| System.Int32 |
Show(String, String, MessageBoxButtons)
Displays a message box with specified text, caption, and buttons.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, Image, Size)
Displays a message box with specified text, caption, buttons, and icon.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Drawing.Image | image | The image used instead of system icon. |
| System.Drawing.Size | imageSize | Size of the image. If empty, original image size is used. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, Image, Size, String)
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | |
| System.String | caption | |
| System.Windows.Forms.MessageBoxButtons | buttons | |
| System.Drawing.Image | image | |
| System.Drawing.Size | imageSize | |
| System.String | details |
Returns
| Type |
|---|
| System.Windows.Forms.DialogResult |
Show(String, String, MessageBoxButtons, Image, Size, MessageBoxDefaultButton)
Displays a message box with the specified text, caption, buttons, icon, and default button.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize, MessageBoxDefaultButton defaultButton)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Drawing.Image | image | The image used instead of system icon. |
| System.Drawing.Size | imageSize | Size of the image. If empty, original image size is used. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, Image, Size, MessageBoxDefaultButton, MessageBoxOptions)
Displays a message box with the specified text, caption, buttons, icon, default button, and options.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize, MessageBoxDefaultButton defaultButton, MessageBoxOptions options)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Drawing.Image | image | The image used instead of system icon. |
| System.Drawing.Size | imageSize | Size of the image. If empty, original image size is used. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
| System.Windows.Forms.MessageBoxOptions | options | One of the System.Windows.Forms.MessageBoxOptions values that specifies which display and association options will be used for the message box. You may pass in 0 if you wish to use the defaults. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, Image, Size, MessageBoxDefaultButton, MessageBoxOptions, Boolean)
Displays a message box with the specified text, caption, buttons, icon, default button, options, and Help button.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize, MessageBoxDefaultButton defaultButton, MessageBoxOptions options, bool displayHelpButton)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Drawing.Image | image | The image used instead of system icon. |
| System.Drawing.Size | imageSize | Size of the image. If empty, original image size is used. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
| System.Windows.Forms.MessageBoxOptions | options | One of the System.Windows.Forms.MessageBoxOptions values that specifies which display and association options will be used for the message box. You may pass in 0 if you wish to use the defaults. |
| System.Boolean | displayHelpButton | true to show the Help button; otherwise, false. The default is false. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, Image, Size, MessageBoxDefaultButton, MessageBoxOptions, CancelEventHandler)
Displays a message box with the specified text, caption, buttons, icon, default button, options, and Help button, using the specified Help file.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize, MessageBoxDefaultButton defaultButton, MessageBoxOptions options, CancelEventHandler helpButtonClickHandler)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Drawing.Image | image | The image used instead of system icon. |
| System.Drawing.Size | imageSize | Size of the image. If empty, original image size is used. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
| System.Windows.Forms.MessageBoxOptions | options | One of the System.Windows.Forms.MessageBoxOptions values that specifies which display and association options will be used for the message box. You may pass in 0 if you wish to use the defaults. |
| System.ComponentModel.CancelEventHandler | helpButtonClickHandler | The help button click handler. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, String)
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | |
| System.String | caption | |
| System.Windows.Forms.MessageBoxButtons | buttons | |
| System.String | details |
Returns
| Type |
|---|
| System.Windows.Forms.DialogResult |
Show(String, String, MessageBoxButtons, MessageBoxIcon)
Displays a message box with specified text, caption, buttons, and icon.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Windows.Forms.MessageBoxIcon | icon | One of the System.Windows.Forms.MessageBoxIcon values that specifies which icon to display in the message box. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, MessageBoxIcon, String)
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | |
| System.String | caption | |
| System.Windows.Forms.MessageBoxButtons | buttons | |
| System.Windows.Forms.MessageBoxIcon | icon | |
| System.String | details |
Returns
| Type |
|---|
| System.Windows.Forms.DialogResult |
Show(String, String, MessageBoxButtons, MessageBoxIcon, MessageBoxDefaultButton)
Displays a message box with the specified text, caption, buttons, icon, and default button.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultButton)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Windows.Forms.MessageBoxIcon | icon | One of the System.Windows.Forms.MessageBoxIcon values that specifies which icon to display in the message box. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, MessageBoxIcon, MessageBoxDefaultButton, MessageBoxOptions)
Displays a message box with the specified text, caption, buttons, icon, default button, and options.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultButton, MessageBoxOptions options)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Windows.Forms.MessageBoxIcon | icon | One of the System.Windows.Forms.MessageBoxIcon values that specifies which icon to display in the message box. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
| System.Windows.Forms.MessageBoxOptions | options | One of the System.Windows.Forms.MessageBoxOptions values that specifies which display and association options will be used for the message box. You may pass in 0 if you wish to use the defaults. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, MessageBoxIcon, MessageBoxDefaultButton, MessageBoxOptions, Boolean)
Displays a message box with the specified text, caption, buttons, icon, default button, options, and Help button.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultButton, MessageBoxOptions options, bool displayHelpButton)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Windows.Forms.MessageBoxIcon | icon | One of the System.Windows.Forms.MessageBoxIcon values that specifies which icon to display in the message box. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
| System.Windows.Forms.MessageBoxOptions | options | One of the System.Windows.Forms.MessageBoxOptions values that specifies which display and association options will be used for the message box. You may pass in 0 if you wish to use the defaults. |
| System.Boolean | displayHelpButton | true to show the Help button; otherwise, false. The default is false. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(String, String, MessageBoxButtons, MessageBoxIcon, MessageBoxDefaultButton, MessageBoxOptions, CancelEventHandler)
Displays a message box with the specified text, caption, buttons, icon, default button, options, and Help button, using the specified Help file.
Declaration
public static DialogResult Show(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultButton, MessageBoxOptions options, CancelEventHandler helpButtonClickHandler)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Windows.Forms.MessageBoxIcon | icon | One of the System.Windows.Forms.MessageBoxIcon values that specifies which icon to display in the message box. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
| System.Windows.Forms.MessageBoxOptions | options | One of the System.Windows.Forms.MessageBoxOptions values that specifies which display and association options will be used for the message box. You may pass in 0 if you wish to use the defaults. |
| System.ComponentModel.CancelEventHandler | helpButtonClickHandler | The help button click handler. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(IWin32Window, String)
Displays a message box in front of the specified object and with the specified text.
Declaration
public static DialogResult Show(IWin32Window owner, string text)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | The owner. |
| System.String | text | The text. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(IWin32Window, String, String)
Declaration
public static DialogResult Show(IWin32Window owner, string text, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | |
| System.String | text | |
| System.String | details |
Returns
| Type |
|---|
| System.Windows.Forms.DialogResult |
Show(IWin32Window, String, String, String)
Displays a message box in front of the specified object and with the specified text and caption.
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | An implementation of System.Windows.Forms.IWin32Window that will own the modal dialog box. |
| System.String | text | The text to display in the message box. |
| System.String | caption | The text to display in the title bar of the message box. |
| System.String | details |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(IWin32Window, String, String, String[])
To Show MessageBoxAdv
Declaration
public static int Show(IWin32Window owner, string text, string caption, string[] buttons)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | Form |
| System.String | text | MessageBoxAdv Text |
| System.String | caption | MessageBoxAdv Caption |
| System.String[] | buttons | Custom Buttons Collection |
Returns
| Type |
|---|
| System.Int32 |
Show(IWin32Window, String, String, String[], Image, Size)
To Show MessageBoxAdv
Declaration
public static int Show(IWin32Window owner, string text, string caption, string[] buttons, Image image, Size imageSize)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | Form |
| System.String | text | MessageBoxAdv Text |
| System.String | caption | MessageBoxAdv Caption |
| System.String[] | buttons | Custom Buttons Collection |
| System.Drawing.Image | image | Image to be displayed in MessageBoxAdv |
| System.Drawing.Size | imageSize | Size of the Image |
Returns
| Type | Description |
|---|---|
| System.Int32 | Selected Button Index |
Show(IWin32Window, String, String, String[], Image, Size, String)
Declaration
public static int Show(IWin32Window owner, string text, string caption, string[] buttons, Image image, Size imageSize, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | |
| System.String | text | |
| System.String | caption | |
| System.String[] | buttons | |
| System.Drawing.Image | image | |
| System.Drawing.Size | imageSize | |
| System.String | details |
Returns
| Type |
|---|
| System.Int32 |
Show(IWin32Window, String, String, String[], String)
Declaration
public static int Show(IWin32Window owner, string text, string caption, string[] buttons, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | |
| System.String | text | |
| System.String | caption | |
| System.String[] | buttons | |
| System.String | details |
Returns
| Type |
|---|
| System.Int32 |
Show(IWin32Window, String, String, String[], MessageBoxIcon)
To Show MessageBoxAdv
Declaration
public static int Show(IWin32Window owner, string text, string caption, string[] buttons, MessageBoxIcon icon)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | Form |
| System.String | text | MessageBoxAdv Text |
| System.String | caption | MessageBoxAdv Caption |
| System.String[] | buttons | Custom Buttons Collection |
| System.Windows.Forms.MessageBoxIcon | icon | Icon to be displayed in MessageBoxAdv |
Returns
| Type | Description |
|---|---|
| System.Int32 | Selected Button Index |
Show(IWin32Window, String, String, String[], MessageBoxIcon, String)
Declaration
public static int Show(IWin32Window owner, string text, string caption, string[] buttons, MessageBoxIcon icon, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | |
| System.String | text | |
| System.String | caption | |
| System.String[] | buttons | |
| System.Windows.Forms.MessageBoxIcon | icon | |
| System.String | details |
Returns
| Type |
|---|
| System.Int32 |
Show(IWin32Window, String, String, MessageBoxButtons)
Displays a message box in front of the specified object and with the specified text, caption, and buttons.
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | The owner. |
| System.String | text | The text to display in the message box. |
| System.String | caption | The caption. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(IWin32Window, String, String, MessageBoxButtons, Image, Size)
Displays a message box in front of the specified object and with the specified text, caption, buttons, and icon.
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | The owner. |
| System.String | text | The text. |
| System.String | caption | The caption. |
| System.Windows.Forms.MessageBoxButtons | buttons | The buttons. |
| System.Drawing.Image | image | The image used instead of system icon. |
| System.Drawing.Size | imageSize | Size of the image. If empty, original image size is used. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(IWin32Window, String, String, MessageBoxButtons, Image, Size, String)
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | |
| System.String | text | |
| System.String | caption | |
| System.Windows.Forms.MessageBoxButtons | buttons | |
| System.Drawing.Image | image | |
| System.Drawing.Size | imageSize | |
| System.String | details |
Returns
| Type |
|---|
| System.Windows.Forms.DialogResult |
Show(IWin32Window, String, String, MessageBoxButtons, Image, Size, MessageBoxDefaultButton)
Displays a message box in front of the specified object and with the specified text, caption, buttons, icon, and default button.
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize, MessageBoxDefaultButton defaultButton)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | The owner. |
| System.String | text | The text to display in the message box. |
| System.String | caption | The caption. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Drawing.Image | image | The image used instead of system icon. |
| System.Drawing.Size | imageSize | Size of the image. If empty, original image size is used. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(IWin32Window, String, String, MessageBoxButtons, Image, Size, MessageBoxDefaultButton, MessageBoxOptions)
Displays a message box in front of the specified object and with the specified text, caption, buttons, icon, default button, and options.
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, Image image, Size imageSize, MessageBoxDefaultButton defaultButton, MessageBoxOptions options)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | The owner. |
| System.String | text | The text. |
| System.String | caption | The caption. |
| System.Windows.Forms.MessageBoxButtons | buttons | The buttons. |
| System.Drawing.Image | image | The image used instead of system icon. |
| System.Drawing.Size | imageSize | Size of the image. If empty, original image size is used. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values the specifies the default button for the message box. |
| System.Windows.Forms.MessageBoxOptions | options | The options. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(IWin32Window, String, String, MessageBoxButtons, String)
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, string details)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | |
| System.String | text | |
| System.String | caption | |
| System.Windows.Forms.MessageBoxButtons | buttons | |
| System.String | details |
Returns
| Type |
|---|
| System.Windows.Forms.DialogResult |
Show(IWin32Window, String, String, MessageBoxButtons, MessageBoxIcon)
Displays a message box in front of the specified object and with the specified text, caption, buttons, and icon.
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | The owner. |
| System.String | text | The text. |
| System.String | caption | The caption. |
| System.Windows.Forms.MessageBoxButtons | buttons | The buttons. |
| System.Windows.Forms.MessageBoxIcon | icon | The icon. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(IWin32Window, String, String, MessageBoxButtons, MessageBoxIcon, MessageBoxDefaultButton)
Displays a message box in front of the specified object and with the specified text, caption, buttons, icon, and default button.
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultButton)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | The owner. |
| System.String | text | The text to display in the message box. |
| System.String | caption | The caption. |
| System.Windows.Forms.MessageBoxButtons | buttons | One of the System.Windows.Forms.MessageBoxButtons values that specifies which buttons to display in the message box. |
| System.Windows.Forms.MessageBoxIcon | icon | The icon. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values that specifies the default button for the message box. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |
Show(IWin32Window, String, String, MessageBoxButtons, MessageBoxIcon, MessageBoxDefaultButton, MessageBoxOptions)
Displays a message box in front of the specified object and with the specified text, caption, buttons, icon, default button, and options.
Declaration
public static DialogResult Show(IWin32Window owner, string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon, MessageBoxDefaultButton defaultButton, MessageBoxOptions options)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Windows.Forms.IWin32Window | owner | The owner. |
| System.String | text | The text. |
| System.String | caption | The caption. |
| System.Windows.Forms.MessageBoxButtons | buttons | The buttons. |
| System.Windows.Forms.MessageBoxIcon | icon | The icon. |
| System.Windows.Forms.MessageBoxDefaultButton | defaultButton | One of the System.Windows.Forms.MessageBoxDefaultButton values the specifies the default button for the message box. |
| System.Windows.Forms.MessageBoxOptions | options | The options. |
Returns
| Type | Description |
|---|---|
| System.Windows.Forms.DialogResult | One of the System.Windows.Forms.DialogResult values. |