Skip to content

DllCall implemented? #154

Answered by spyoungtech
dusty-dusty asked this question in Q&A
Discussion options

You must be logged in to vote

Several functionalities from AHK are omitted from the library because Python has similar functionality in the standard library. For example, AHK's Process functionality is omitted because Python has a subprocess module.

Similarly, it's possible to work with DLLs directly in Python using the ctypes library: https://docs.python.org/3/library/ctypes.html
For that reason, DllCall from AHK is not implemented.

I suppose you might do something like this using ctypes:

from ctypes import windll

windll.user32.mouse_event(...)

Of course if you find it easier to work with AHK, you can always use run_script from the python library. Though, it seems like an extra unnecessary layer.

script = 'DllCall("…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by spyoungtech

This comment has been hidden.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
question Further information is requested
2 participants
Converted from issue

This discussion was converted from issue #117 on June 23, 2022 00:29.