ACAT.Lib.Extension.DialogUtils.initYesNoDialog C# (CSharp) Méthode

initYesNoDialog() private static méthode

Creates the Yes/No dialog form
private static initYesNoDialog ( String title, String caption ) : Form
title String title of the dialog
caption String caption to display
Résultat System.Windows.Forms.Form
        private static Form initYesNoDialog(String title, String caption)
        {
            const String panelClass = "YesNoDialog";

            Log.Debug("Creating panel " + panelClass);
            Form form = Context.AppPanelManager.CreatePanel(panelClass);
            if (form == null)
            {
                return null;
            }

            if (form is IExtension)
            {
                var invoker = (form as IExtension).GetInvoker();
                invoker.SetValue("TitleBar", String.IsNullOrEmpty(title) ? "ACAT" : title);
                invoker.SetValue("Caption", caption);
            }

            return form;
        }