Control.
Gives focus to the control.
control.SetFocus ( )
SetFocus gives the input focus to the specified control (that is, makes it the control to which the GUI directs keystrokes).
It is not necessary to call SetFocus prior to using any of the functions that operate on controls. Call it in cases where you plan to use TypeKeys to pass keystrokes to a pop-up window, and you need to display the window first.
TextEditor.Document.SetFocus ()