I know this subject has been beaten half-to-death but I am confused and could use some help. I am creating an application will send text data to another running program. The problem is how do I determine which program/application HAD the focus just before I set the focus to my application.
What I want to do is to initiate/create some text from within my program that can be sent to the LAST program that had the PREVIOUS focus without knowing what that program was or is.
How do I use Get/SetForeGroundWindow and AppActivate to perform thi function. Also I have seen some earlier responses that use a TIMER, is this required? do I need to change focus manually?
Thanks in advance,