The existing SendKeys class does not have a managed way to activate an external application. MSDN recommends that you should use the FindWindow and SetForegroundWindow APIs.
However, this alone does not ensure that the desired application will have keyboard focus while the keys are being sent. This replacement module sends keys directly to the specified window without error. |