Solved

poping strings without pressing keys from the keyboard

Posted on 2001-08-25
3
150 Views
Last Modified: 2010-04-06
how can i popup letters or like
pressing the enter key without pressing
keys in the keyboard.

example: If im in the notepad(active window)
         after a few seconds a word will
         be written on it,(like it pops right away
         there!)


What i mean i do not know the name of
the active window or application, and
i want to send some message on it
how can i do this? and is it possible
to display all application names found
who are running in my computer and specially
the active one.
0
Comment
Question by:ryan_sabarre
3 Comments
 
LVL 1

Expert Comment

by:sundayboys
ID: 6425927
already comment
0
 
LVL 20

Accepted Solution

by:
Madshi earned 100 total points
ID: 6426090
Seems like a double post question?

Anyway, here is my comment:

I would suggest using keybd_event. It just simulates key pressed and doesn't care which application is currently in the foreground.

E.g. this one simulates pressing and releasing the control key:

  keybd_event(VK_CONTROL, 0, 0,               0);
  keybd_event(VK_CONTROL, 0, KEYEVENTF_KEYUP, 0);

Regards, Madshi.
0
 
LVL 3

Expert Comment

by:rondi
ID: 6428056
yeah keybd_event worked for me;
I used it to take screen snapshots but it'll do for anything
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
A company’s greatest vulnerability is their email. CEO fraud, ransomware and spear phishing attacks are the no1 threat to a company’s security. Cybercrime is responsible for the largest loss of money to companies today with losses projected to r…

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now