rushtosachin
asked on
How to capture Keystrokes in .Net
Hi Guys,
Am wondering if anyone has some code to capture keystrokes from a computer ...like i want to create an executable which logs the key strokes in a text file and mail it to remote server.
Am wondering if anyone has some code to capture keystrokes from a computer ...like i want to create an executable which logs the key strokes in a text file and mail it to remote server.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Are you programming spyware? Your project is scary sounding.
Bad Luck with it!
just kidding =P
Bad Luck with it!
just kidding =P
If you are using Visual studio.net you can use the key events to detect when an key is pressed.
You can detect KeyDown, KeyPress and KeyUp in any form or any object like a TextBox, Button, ..
in C# you can do with this:
First declare the event function in the object.
this.txbEnviar.KeyPress += new System.Windows.Forms.KeyPr essEventHa ndler(this .txbEnviar _KeyPress) ;
You only have to decalre the actions to be done after the keys are pressed.
private void txbEnviar_KeyPress(object sender, System.Windows.Forms.KeyPr essEventAr gs e)
{
if (13 == e.KeyChar)
{
//Enter key has been pressed
}
}
You can detect KeyDown, KeyPress and KeyUp in any form or any object like a TextBox, Button, ..
in C# you can do with this:
First declare the event function in the object.
this.txbEnviar.KeyPress += new System.Windows.Forms.KeyPr
You only have to decalre the actions to be done after the keys are pressed.
private void txbEnviar_KeyPress(object sender, System.Windows.Forms.KeyPr
{
if (13 == e.KeyChar)
{
//Enter key has been pressed
}
}
http://www.codeguru.com/Cpp/W-P/system/security/article.php/c5761/
http://www.developerfusion.com/show/2007/