Пример #1
0
        public static TaskDialogResult Show(string text, string caption, _MessageBoxButtons buttons, _MessageBoxIcon icon)
        {
            TaskDialog td = new TaskDialog
            {
                StandardButtons = (TaskDialogStandardButtons)buttons,
                Icon            = (TaskDialogStandardIcon)icon,
                Caption         = caption,
                InstructionText = ((TaskDialogStandardIcon)icon).ToString(),
                DetailsExpanded = true,
                Text            = text,
            };

            return(td.Show());
        }
Пример #2
0
        public static TaskDialogResult Show(IWin32Window owner, string text, string caption, _MessageBoxButtons buttons)
        {
            TaskDialog td = new TaskDialog {
                StandardButtons = (TaskDialogStandardButtons)buttons,
                Icon            = TaskDialogStandardIcon.None,
                Caption         = caption,
                InstructionText = (TaskDialogStandardIcon.None).ToString(),
                DetailsExpanded = true,
                Text            = text,
            };

            return(td.Show());
        }