C # Driver-level analog key operation

Source: Internet
Author: User

C # Driver-level analog key operation2013-09-26 03:17 AB tert -447 3 <-Click on the numbers on the left to "save" a bar

Yesterday encountered a program that automatically entered the Tenpay password task.

Because the Tenpay password control is secure, it cannot be manipulated by traditional keybd_event.

Find a lot of information on the Internet, finally found Winio.dll this port operation driver components to solve this problem.

The first is the need to encapsulate Winio.dll in C # to make it more usable.

I've got it all encapsulated here, SupKey.dll.

    1. Note that my environment is win2003 32-bit, 63-bit or other version of the time may need to download the corresponding Winio.dll.
    2. Note that it takes a short period of time for a keyboard event to be sent each time.

And then there's the actual environment under test.

First Sendwinio to load the driver, remember to uninstall Endwinio after the end.

VarSupkey=New Supkey.Supkey(); Supkey.Sendwinio();Load Supkey.Mykeydown(Supkey. Supkey. VkA);Input Asupkey.Mykeydown(Supkey. Supkey. Vkb);Input Bsupkey.Mykeydown(Supkey. Supkey. Vkc);Input Csupkey.Mykeydown(Supkey. Supkey. Vkd);Input Dsupkey.Mykeydown(Supkey. Supkey. VkNum0);//input 0supkey. Mykeydown//input 1supkey. Mykeydown//input 2supkey. Mykeydown//input 3supkey. Endwinio (); //uninstall              

Download source code

C # Driver-level analog key operation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.