예제 #1
0
 public static string Perform(Window parent, string title, string caption, string initialText)
 {
     var window = new TextEditWindow().Create(title, caption, initialText);
     window.Owner = parent;
     window.WindowStartupLocation = WindowStartupLocation.CenterOwner;
     var dialogResult = window.ShowDialog();
     var result = dialogResult == true ? window.Edit.Text : null;
     return result;
 }
예제 #2
0
        public static string Perform(Window parent, string title, string caption, string initialText)
        {
            var window = new TextEditWindow().Create(title, caption, initialText);

            window.Owner = parent;
            window.WindowStartupLocation = WindowStartupLocation.CenterOwner;
            var dialogResult = window.ShowDialog();
            var result       = dialogResult == true ? window.Edit.Text : null;

            return(result);
        }