The MASM Forum

General => The Laboratory => Topic started by: hutch-- on September 09, 2014, 12:38:13 AM

Title: Keys demo example with a working library.
Post by: hutch-- on September 09, 2014, 12:38:13 AM
I have put together a demo using the key procedures that seemed to work OK, a couple of macros in the include file and a batch file to build the library that contains the procedures.

It is bundled with a text editor rom the masm32 examples so that they keys used to operate the menu would remain the same across different language and OS versions. It starts the editor, types in a quote from Hamlet then uses the C text macro to type in a quote from Lewis Carroll's "Through The Looking Glass".

It then opens the file save as dialog and saves the file to disk.

The only real weakness I can find is you must not click the mouse while the keys are being sent as you change the focus and the key get sent almost anywhere. You also need to be careful with some repeat keys as you can lose one if you don't specify a time lag between them.

PS: I found the solution to the mouse clicks while its running.

    fn BlockInput,TRUE      ; before to disable the mouse
    fn BlockInput,FALSE    ; after to re-enable the mouse
Title: Re: Keys demo example with a working library.
Post by: jj2007 on November 17, 2014, 07:03:39 PM
Could the coder of these bots (#2 (http://masm32.com/board/index.php?topic=3773.msg39977#msg39977)) pleaz teach them proper English? Can't be so difficult :eusa_boohoo:
Title: Re: Keys demo example with a working library.
Post by: hutch-- on November 17, 2014, 10:09:51 PM
Janitor service strikes again.  :P
Title: Re: Keys demo example with a working library.
Post by: habran on November 17, 2014, 10:52:56 PM
CLEANER is a better word for that ;)
Remember Harvey Keitel in a movie Pulp Fiction :badgrin:
Title: Re: Keys demo example with a working library.
Post by: Searisava on December 29, 2014, 08:23:13 PM
Can to implement it?