Replace selection in text boxes.