Jump to content

hotkeyset ?


Travis
 Share

Recommended Posts

So i use the following function in this program I am writing

Hotkeyset("{ASC 097},"randomfunc")

For some reason, the ascii character 097 (which corresponds to the lower-case alphabet character "a") only wants to work when I type a CAPITAL A (shift + A)

If I change the ascii code to the proper code for a capital A, it works fine just like it should. But in this case I can't seem to capture a lowercase letter.

Here is the program that I have so far, you can run it and I would be interested in what results you get.

Hotkeyset("{ASC 097}","randomfunc")

While 1

Sleep(100)

WEnd

Func randomfunc()

msgbox(0,"","detected a stroke")

;$file = fileopen("c:\users\travis\desktop\test.txt",1)

;filewriteline($file,"a")a

EndFunc

Note that I've commented-out the lines that involve writing a file to your (likely) non-existant desktop for user: Travis.

Link to comment
Share on other sites

lopolop, indeed is the right ascii code. But it doesn't want to capture the a character for some reason. The capital A character captures fine on both codes (like, the correct code and 097).

But I just used Hotkeyset("a","randomfumc") and it worked fine. Maybe the help file was not updated since an older version of autoit or something like that.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...