Required header
using System.Windows.Forms;Code
SendKeys.Send(string);Example
private void Auto_Type()
{
string str = "Hello, world!!";
SendKeys.Send("A"); //program types "A"
SendKeys.Send(str); //program types "Hello, world!!"
SendKeys.Send("{ENTER}") //program presses 'ENTER'
}ถ้านำไปประยุกต์ใช้งานกับ Timer สามารถสร้างเป็นบอท Auto Type ได้สบายๆsee more : http://msdn.microsoft.com/en-us/library/system.windows.forms.sendkeys.aspx
No comments:
Post a Comment