🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.cppbuilder.nativeapi
3 messages
3 total messages Started by sam Sun, 12 Aug 2007 18:06
SendInput and wait
#1482
Author: sam
Date: Sun, 12 Aug 2007 18:06
9 lines
1281 bytes
I use SendInput API for sending keystrokes to an application and then use a 
loop for waiting a time :
for(int y=0;y< iTempo;y++)Application->ProcessMessages();
but this doesn't work at all time because it depends on the time that the 
application target takes for handling the keystrokes.
So Does someone get a way for waiting the exacte time until an application 
handle the keystrokes ?

Sam 
Re: SendInput and wait
#1483
Author: Bob Gonder
Date: Mon, 13 Aug 2007 01:23
12 lines
1384 bytes
sam wrote:

>So Does someone get a way for waiting the exacte time until an application 
>handle the keystrokes ?

What does the application do that you need to wait for?
Wharever it is, wait for that to happen.

If you are sending multiple SendInput(), you might try sending
an array of keystokes instead of one-at-a-time.

You might also look at using SendMessage()
Re: SendInput and wait
#1487
Author: Asger Jorgensen
Date: Mon, 13 Aug 2007 18:31
9 lines
1099 bytes
What about

keybd_event(VK_TAB, 0, 0, 0);
VK_TAB can be any virtual keycode

Just an idea though

Kind regards
Asger
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads