SendKeys.SendWait doesn't works

Posted by Guy on Stack Overflow See other posts from Stack Overflow or by Guy
Published on 2010-05-16T07:21:42Z Indexed on 2010/05/16 7:30 UTC
Read the original article Hit count: 260

Filed under:
|

My target is to send keyboard events to external application. From my application, I'm launching a C# exe (console application) that bring the target application to the front and uses SendKeys.SendWait to send keyboards events. I ran into a rate case were the command don't have any affect. When debugging it, it works but when running it not in debug it fails. I think it as something to do with the fact that when debugging my application is the active application.

© Stack Overflow or respective owner

Related posts about sendkeys

  • .NET sendkeys to calculator

    as seen on Stack Overflow - Search for 'Stack Overflow'
    The sendkeys code below works well for Notepad but it doesn't work for Calculator. What is the problem? (It's another problem compared to what I sent here http://stackoverflow.com/questions/2604486/c-sendkeys-problem) [DllImport("user32.dll", CharSet = CharSet.Unicode)] public static extern IntPtr… >>> More

  • C# sendkeys to calculator

    as seen on Stack Overflow - Search for 'Stack Overflow'
    The sendkeys code below works well for Notepad but it doesn't work for Calculator. What is the problem? (It's another problem compared to what I sent here http://stackoverflow.com/questions/2604486/c-sendkeys-problem) [DllImport("user32.dll", CharSet = CharSet.Unicode)] public static extern IntPtr… >>> More

  • Cisco Configuration backup with Windows Script.

    as seen on Server Fault - Search for 'Server Fault'
    We have a client with a lot of Cisco Devices and we would like to automate the backups of these devices through telnet. We have both 2003 and 2008 servers and ideally use tftp to back it up. I wrote this: Set WshShell = WScript.CreateObject("WScript.Shell") Dim fso Set fso = CreateObject("Scripting… >>> More

  • C# sendkeys problem

    as seen on Stack Overflow - Search for 'Stack Overflow'
    THe code below I copied from MSDN with a bit of modification: [DllImport("user32.dll", CharSet = CharSet.Unicode)] public static extern IntPtr FindWindow(string lpClassName,string lpWindowName); DllImport("User32")] public static extern bool SetForegroundWindow(IntPtr hWnd); int cnt = 0; private… >>> More

  • Sendkeys problem from .NET program

    as seen on Stack Overflow - Search for 'Stack Overflow'
    THe code below I copied from MSDN with a bit of modification: [DllImport("user32.dll", CharSet = CharSet.Unicode)] public static extern IntPtr FindWindow(string lpClassName,string lpWindowName); DllImport("User32")] public static extern bool SetForegroundWindow(IntPtr hWnd); int cnt = 0; private… >>> More

Related posts about c#