Search found 1853 matches

by HotKeyIt
27 Jul 2019, 15:34
Forum: AutoHotkey_H
Topic: [Guide] Compiling Ahk_h's source step by step
Replies: 28
Views: 4795

Re: [Guide] Compiling Ahk_h's source step by step

What do you mean by ALL compilation options and what error do you get otherwise?
by HotKeyIt
25 Jul 2019, 15:35
Forum: Ask For Help
Topic: About AhkThread (Parent, Child and Sibling)
Replies: 22
Views: 1662

Re: About AhkThread (Parent, Child and Sibling)

As mentioned use CriticalObject to communicate and share variables between dlls: #NoEnv #NoTrayIcon SetBatchlines, -1 #SingleInstance, Force Global share, StopDll share:=CriticalObject({S1Count:0,S2Count:0,DllThreadS1:"",DllThreadS2:"",DllThreadS3:"",DllThreadS4:"",DllThreadS5:""}) StopDll:=Critical...
by HotKeyIt
25 Jul 2019, 05:52
Forum: Ask For Help
Topic: About AhkThread (Parent, Child and Sibling)
Replies: 22
Views: 1662

Re: About AhkThread (Parent, Child and Sibling)

Use the same way we used CriticalObject above (share) and do share.DllOtherThread....
If you can't get it right, post full example script.
by HotKeyIt
24 Jul 2019, 11:20
Forum: Ask For Help
Topic: About AhkThread (Parent, Child and Sibling)
Replies: 22
Views: 1662

Re: About AhkThread (Parent, Child and Sibling)

Use CriticalObject to communicate and share data between threads.
The only thing that can cause the crash is DllOtherThread as far as I can see, so having this in a CrticalObject and make sure that you clear it properly should solve the problem.
by HotKeyIt
22 Jul 2019, 19:19
Forum: Ask For Help
Topic: Launch Function & Catch Object in DllThread
Replies: 5
Views: 686

Re: Launch Function & Catch Object in DllThread

SetBatchlines,-1 fun:=Func("Obj") for i, j in fun.(3, 5) MsgBox % "Main Obj:`n" i ": " j test := " ( SetBatchlines,-1 fun:=Object(" (&fun) ") for i, j in fun.(3, 5) MsgBox `% ""test Obj:``n"" i "": "" j )" AhkDll := AhkThread(test) While AhkDll.ahkReady() Sleep 100 SoundBeep, 8000 ExitApp obj(a, b)...
by HotKeyIt
22 Jul 2019, 19:06
Forum: Ask For Help
Topic: About AhkThread (Parent, Child and Sibling)
Replies: 22
Views: 1662

Re: About AhkThread (Parent, Child and Sibling)

Try this: #NoTrayIcon #SingleInstance, Force share:=CriticalObject({count:0,s1Thread:"",s2Thread:""}) s1Script := " ( #NoTrayIcon share:=CriticalObject(" (&share) ") Loop ToolTip `% ""s1 count: "" ++share.count )" s2Script := " ( #NoTrayIcon share:=CriticalObject(" (&share) ") Loop MsgBox `% ""Count...
by HotKeyIt
10 Jul 2019, 17:52
Forum: Ask For Help
Topic: About AhkThread (Parent, Child and Sibling)
Replies: 22
Views: 1662

Re: About AhkThread (Parent, Child and Sibling)

Parameter also needs to be a string!SIBLING1Thread:=AhkThread(script,"" (&SIBLING1Script)) but you seems never to use it.
by HotKeyIt
10 Jul 2019, 16:49
Forum: Ask For Help
Topic: About ahkFunction
Replies: 7
Views: 513

Re: About ahkFunction

Sorry it should be c := PaternThread.ahkFunction("function", 5 "",8 "")
by HotKeyIt
10 Jul 2019, 16:47
Forum: Ask For Help
Topic: About AhkThread (Parent, Child and Sibling)
Replies: 22
Views: 1662

Re: About AhkThread (Parent, Child and Sibling)

Can you put a very simple script together doing the same?
by HotKeyIt
10 Jul 2019, 15:58
Forum: Ask For Help
Topic: About AhkThread (Parent, Child and Sibling)
Replies: 22
Views: 1662

Re: About AhkThread (Parent, Child and Sibling)

Try Irmao01Thread.AhkAssign("Irmao02ThreadPtr", (&Irmao02Thread) "")
by HotKeyIt
10 Jul 2019, 15:56
Forum: Ask For Help
Topic: About ahkFunction
Replies: 7
Views: 513

Re: About ahkFunction

Try c := PaternThread.ahkFunction(a,b)
by HotKeyIt
08 Jul 2019, 18:05
Forum: AutoHotkey v2 Development
Topic: [a103]Unfortunate collision of a few things
Replies: 20
Views: 1585

Re: [a103]Unfortunate collision of a few things

I would not call it bad.
I think it makes it easier for the parser to have clear rules.
by HotKeyIt
08 Jul 2019, 16:20
Forum: AutoHotkey v2 Development
Topic: [a103]Unfortunate collision of a few things
Replies: 20
Views: 1585

Re: [a103]Unfortunate collision of a few things

If I remember correct from the changes that is how it should be. The error also does say properly that only one parameter is allowed for return but I remember it was not obvious for me because I am used to do it like this. Probably error should also say: "Return" accepts at most 1 parameter. Specifi...
by HotKeyIt
08 Jul 2019, 16:14
Forum: AutoHotkey_H
Topic: Ahk H memory error <HELP> Topic is solved
Replies: 2
Views: 490

Re: Ahk H memory error <HELP> Topic is solved

Make sure that Port is also a string and not number:Server.Bind(["0.0.0.0", "1337"])
This is because AHK_H v2 allows to pass a pointer to AStr, WStr and Str and this is assumed if parameter is a number.
by HotKeyIt
08 Jul 2019, 15:42
Forum: AutoHotkey v2 Development
Topic: [a103]Unfortunate collision of a few things
Replies: 20
Views: 1585

Re: [a103]Unfortunate collision of a few things

return (a := 0, b := 1) or return (b := 1, a := 0) depending on what you want to return.
by HotKeyIt
06 Jul 2019, 19:51
Forum: AutoHotkey_H
Topic: About Dynamic variable in AhkThread Topic is solved
Replies: 5
Views: 612

Re: About Dynamic variable in AhkThread Topic is solved

Here is another example: VarCrit:=CriticalObject({test:"this is a test",test1:"this is another test"}) ahk:=AhkThread(" ( VarCrit:=CriticalObject(" (&VarCrit) ") Loop 2 { out:="""" for k, v in VarCrit out.=v ""``n"" MsgBox `% out } )") Sleep 400 VarCrit.test2:="this is new test" While ahk.ahkReady()...
by HotKeyIt
06 Jul 2019, 19:19
Forum: AutoHotkey_H
Topic: About Dynamic variable in AhkThread Topic is solved
Replies: 5
Views: 612

Re: About Dynamic variable in AhkThread Topic is solved

You include them all in the object and you can add another object if needed.
You can also add more keys to the object afterwards, just make sure that you access them via CriticalObject (VarCrit).

Go to advanced search