I've been trying to use the SendKeys functions in a program and have come to the conclusion that it simply won't work for my application ... so I'm trying to figure out how to use the SendInput API. I've been to the VBAPI web-site, but the example they give is currently beyond my understanding. The SendInput API supposedly places events into the input stream, well what is the input stream and how do I direct it to my target application??

My application reads a text file and then controls another application via keyboard action (tried using SendKeys), and finally sends each line of text to the other application.

I guess I'm asking if anyone has or knows of a simple example that uses the SendInput API to send some key strokes or strings to a target application.

Thanks for any help you can provide.

Dave