예제 #1
0
        public static DialogResult ShowDialog(string dialogCaption, string caption, ref string value)
        {
            InputDialog inputDlg = new InputDialog();

            inputDlg.Text          = dialogCaption;
            inputDlg.lblInput.Text = caption;
            inputDlg.edtInput.Text = value;

            DialogResult result = inputDlg.ShowDialog();

            if (result == DialogResult.OK)
            {
                value = inputDlg.edtInput.Text;
            }

            return(result);
        }
예제 #2
0
        private void RenameList( )
        {
            CodeCompletionList selList = lbLists.SelectedItem as CodeCompletionList;

            if (selList == null)
            {
                return;
            }

            string name = String.Empty;

            if (InputDialog.ShowDialog("Rename List", "Name", ref name) != DialogResult.OK)
            {
                return;
            }

            selList.Name = name;
            _isModified  = true;
        }
예제 #3
0
 public static DialogResult ShowDialog(string caption, ref string value)
 {
     return(InputDialog.ShowDialog("Input Dialog", caption, ref value));
 }