VB.net with autohotkey.dll - functions?

Post a reply

Confirmation code
Enter the code exactly as it appears. All letters are case insensitive.
Smilies
:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :| :mrgreen: :geek: :ugeek: :arrow: :angel: :clap: :crazy: :eh: :lolno: :problem: :shh: :shifty: :sick: :silent: :think: :thumbup: :thumbdown: :salute: :wave: :wtf: :yawn: :facepalm: :bravo: :dance: :beard: :morebeard: :xmas: :HeHe: :trollface: :cookie: :rainbow: :monkeysee: :monkeysay: :happybday: :headwall: :offtopic: :superhappy: :terms: :beer:
View more smilies

BBCode is ON
[img] is OFF
[flash] is OFF
[url] is ON
Smilies are ON

Topic review
   

Expand view Topic review: VB.net with autohotkey.dll - functions?

Re: VB.net with autohotkey.dll - functions?

Post by KoHx3 » 18 Jan 2017, 18:41

Hey there - I still have the Problem that I cant use the addscript command.
I'm using the v1 .dll (registered).

The following code wont work (Also tried as Module and other Sub- but nothing worked and I need help.

Code: [Select all] [Expand]GeSHi © Codebox Plus



Any help? The only thing I can get to work is ahktextdll and ahkdll but I need to activate / deactivate the script If the checkbox is checked or not or something like this. D:
And this also should work on a computer without AHK installed. :/

Re: VB.net with autohotkey.dll - functions?

Post by KoHx3 » 11 Jan 2017, 10:26

Thanks for this advice but I'm not that taff to get the sense - nah - to get the functions out of it.
I'm also to stupid to use it correctly if I register the .dll of v1.

I want to combine scripts if the Checkbox is checked or not - but only ask for the Checked state if a button got clicked.
(Yea I do that with Strings at this point cause in my usual code I need them later)

Code: [Select all] [Expand]GeSHi © Codebox Plus

Re: VB.net with autohotkey.dll - functions?

Post by guest3456 » 08 Jan 2017, 11:36

https://hotkeyit.github.io/v2/docs/AHKH_Features.htm

scroll down and look for 'exported functions'

VB.net with autohotkey.dll - functions?

Post by KoHx3 » 08 Jan 2017, 09:39

Hey there,
I want to make some stuff with VB.net and use some ahk scripts.
Actually I just need help to get the functions out of the .dll - and maybe a small example for it.
The Problem is - I dont want to register the autohotkey.dll file.
(Keyword: Export functions)

I found it over here (the way to import functions): https://autohotkey.com/board/topic/108214-autohotkey-library-in-vbnet-verwenden/
(German thread)

I'm using the ahk.dll from Win32w. (From this one https://github.com/HotKeyIt/ahkdll-v1-release because I dont know - this were the one I got redirected to :lol: )
As I see now - there is a v2 version - maybe I should use this, depends on what you say.
Back to topic.

To call the DLL and import the function (ahktextdll were the example) I want to use, I've to use this code:

Code: [Select all]GeSHi © Codebox Plus

Module Module1
<DllImport("AutoHotkey.dll", CallingConvention:=CallingConvention.Cdecl, CharSet:=CharSet.Unicode)>
Function ahktextdll(ByVal script As String, ByVal options As String, ByVal param As String) As Integer
End Function
End Module


But which functions are out there? How I'm able to get them? Is there any list?
I definetly need something to reset the ahk script, add a script to the existing/running script, - something like this.

Hope you can help me out :)
Cheers

Top