|
-
Sep 19th, 2007, 11:43 PM
#1
Thread Starter
Member
[2005] (System.windows.forms.sendkeys.send) Issue
Hello,
I'm trying to create a program that alt tabs and then outputs some keystrokes.
I have tried using:
Code:
System.Windows.Forms.SendKeys.Send("%{TAB}")
When i run it, it will Press alt and then Tab, but it won't release Alt, so it doesn't actually perform the Alt+Tab Correctly.
I have also tried opening a Notepad document and then running this code.
Code:
System.Windows.Forms.SendKeys.Send("Hello")
This didn't output "Hello" into the notepad.
I have also tried using System.windows.forms.sendkeys.sendwait but that hasn't worked either.
Is there an easy way to pause the application? might be usable instead of sending alt+tab.
This code is located in the form load section.
|
\/
Code:
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
End Sub
Thanks.
Appreciate any help given.
-
Sep 20th, 2007, 09:18 PM
#2
Thread Starter
Member
Re: [2005] (System.windows.forms.sendkeys.send) Issue
Can anyone help me?
If more explanation is needed, let me know.
Thanks.
-
Sep 21st, 2007, 12:31 PM
#3
New Member
Re: [2005] (System.windows.forms.sendkeys.send) Issue
Hi, I believe the code is :
Code:
My.Computer.Keyboard.SendKeys("^{C}")
or
Code:
sendkeys.send("^{C}")
just an example and then theres
Code:
SendKeys.sendwait("^{C}")
Im no expert though, just been programming for a few weeks 
the above code sends the "copy" command
EDIT: I misread the message, the above is probably meaningless, I thought you were asking how to use the send keys function!
Last edited by nemesis1977; Sep 21st, 2007 at 12:35 PM.
-
Sep 21st, 2007, 08:04 PM
#4
Thread Starter
Member
Re: [2005] (System.windows.forms.sendkeys.send) Issue
Thanks for the help, i just decided not to implement the alt tab feature, will manually do it, no big issue.
Thanks again.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|