SendKeys.Send()

  • Thread starter Thread starter atr2000
  • Start date Start date
A

atr2000

How can I perform a SendKeys.Send to the current active application from a
windows service? Or is there a different way to do this?

I currently receive the following error message:

System.InvalidOperationException: SendKeys cannot run inside this
application because the application is not handling Windows messages.

Thanks in advance,
atr2000
 
Perhaps if you set the service to allow it to interact with the desktop?

Maybe?
 
Okay I found that. Located in the Services Properties.

I have another question: How do I sendkeys to the currently active cursor
location of the current running application? I am trying to develop a
Remote Desktop Application in VB.NET.
 
As far as I remember, sendkeys will send keystrokes to where the cursor
currently is located. Where ever the cursor is and what ever window has
focus at the time of the function call will get the keys.
 
Back
Top