Hi Wayne,
Does your operating system win9x?
There is an already known issue that the win9x will ingnore the sendkeys
alt+tab.
For details, please refer to:
http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com:
80/support/kb/articles/Q129/8/39.asp&NoWebContent=1
Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! -
www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
--------------------
| X-Tomcat-ID: 161223555
| References: <
[email protected]>
<
[email protected]>
<
[email protected]>
| MIME-Version: 1.0
| Content-Type: text/plain
| Content-Transfer-Encoding: 7bit
| From: (e-mail address removed) (Jeffrey Tan[MSFT])
| Organization: Microsoft
| Date: Fri, 05 Sep 2003 06:43:55 GMT
| Subject: Re: SendKeys Question..
| X-Tomcat-NG: microsoft.public.dotnet.languages.csharp
| Message-ID: <
[email protected]>
| Newsgroups: microsoft.public.dotnet.languages.csharp
| Lines: 72
| Path: cpmsftngxa06.phx.gbl
| Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.languages.csharp:182503
| NNTP-Posting-Host: TOMCATIMPORT2 10.201.218.182
|
|
| Hi Wayne,
|
| I used an another software that can be invoke while pressing certain key
to
| simulate your function.
| This software can hook system wide key stroke and whenever I press
alt+F4,
| the application will get
| invoke, and the active window will not be closed.
|
| I use sendkeys class to send "%{F4}" to my application, but the hook
| application does not get invoked and
| my form gets closed as usual.
|
| I think the sendkeys class bypassed the message queue, so the hook can
not
| get notified.
| In my .net application, the sendkeys class can succeed fire Alt+Tab and
| letting the focus change, but it can not
| fire ctrl+esc.(can not let the start menu pop up)
|
| To work around your problem, I think you can use keybd_event() function
| instead of sendkeys.(In win2000, it seems of that
| it was replaced by sendinput() function).
| May be you also can use sendmessage function to simulate certain hot key.
|
| Also, how does your application get the hot key?
| It used Keyboard hook?
| I think the best way of simulating keyboard send keys event is using
| WH_JOURNALPLAYBACK, please refer to MSDN.
|
| If you still get some problem, do tell me, I am glad to work with you.
|
| Best regards,
| Jeffrey Tan
| Microsoft Online Partner Support
| Get Secure! -
www.microsoft.com/security
| This posting is provided "as is" with no warranties and confers no rights.
|
| --------------------
| | From: "Wayne Gibson" <
[email protected]>
| | Newsgroups: microsoft.public.dotnet.languages.csharp
| | Subject: Re: SendKeys Question..
| | Date: Thu, 4 Sep 2003 14:19:44 +0100
| | Lines: 14
| | Message-ID: <
[email protected]>
| | References: <
[email protected]>
| <
[email protected]>
| | NNTP-Posting-Host: 62.49.252.243
| | X-Trace: news.demon.co.uk 1062681513 26355 62.49.252.243 (4 Sep 2003
| 13:18:33 GMT)
| | X-Complaints-To: (e-mail address removed)
| | NNTP-Posting-Date: Thu, 4 Sep 2003 13:18:33 +0000 (UTC)
| | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
| | X-Priority: 3
| | X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
| | X-MSMail-Priority: Normal
| | Path:
|
cpmsftngxa06.phx.gbl!TK2MSFTNGP08.phx.gbl!newsfeed00.sul.t-online.de!t-onlin
| e.de!kibo.news.demon.net!news.demon.co.uk!demon!not-for-mail
| | Xref: cpmsftngxa06.phx.gbl
microsoft.public.dotnet.languages.csharp:182254
| | X-Tomcat-NG: microsoft.public.dotnet.languages.csharp
| |
| | Thanks, had tried that..
| |
| | I think I forgot to mention, the reason for using this keyboard
| combination
| | is I have some software that providing a short cut key to do something
for
| | me.. This doesn't appear to be picking it up...
| |
| | I also tried Alt+Tab to switch applications and Ctrl+Esc to bring up the
| | start button, But neither of this too work... Any Ideas?
| |
| | Thanks
| |
| | Wayne
| |
| |
| |
|
|