private CommandTextBox GetCommandTextBox(IEnumerable<ITextBoxCommand> commands = null)
        {
            CommandTextBox commandTextBox = new CommandTextBox();
            commandTextBox.OnApplyTemplate();

            if (commands != null)
                commandTextBox.Commands = commands;

            return commandTextBox;
        }
 private void SetText(CommandTextBox commandTextBox, bool useTextProperty, string text)
 {
     if (useTextProperty)
         commandTextBox.Text = text;
     else
         commandTextBox.SetTextBoxText(text);
 }