• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 147
  • Last Modified:

presskey with api

I want to simulate a keypress when a window with a certain classID has focus.  I think I get the findwindow(), but I'm having trouble with the keypress.  Sorry, the points are so low, I'm almost out :(
0
fibdev
Asked:
fibdev
  • 2
  • 2
1 Solution
 
Erick37Commented:
Once the window has focus you can use VB's SendKeys function.
0
 
fibdevAuthor Commented:
I can't find SendKeys anywhere in the Win32API?
0
 
Erick37Commented:
SendKeys is a VB command.

SendKeys "Text to send"

SendKeys "{ENTER}"

You will find it in VB Help.
0
 
fibdevAuthor Commented:
Thanks Erick
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now