Nathan72389's Blog

This is mine!

( keys / messages to unfocused/minimized window

with one comment

I am working on little project that i need to send messages to a window that did not have focus. I had done this before in the past, but from then to now, i got a little rusty on my skills. I decided to write up this little project to give myself a nice “Refresher”.

in this example i am looping through all of the running process looking for “notepad”. when its found, i start looping through all of its controls looking for the “Edit” control (the big white textbox). When i find the handle to that control, i can the send a message to it (in this case its a string). I loop through each character in the string and send it to the control character by character then send the “Enter” key once the loop is over with.

Hopefully there will be someone else that can find this useful, and i would like to give a “Thanks” to the guys over a for their time and effort in putting that site together.

Download Project here!

Written by nathan72389

November 16, 2010 at 2:34 pm

Posted in Misc., Projects, Snippets

One Response

Subscribe to comments with RSS.

  1. very good


    June 11, 2011 at 10:38 am

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: