piccaso Posted August 2, 2006 Share Posted August 2, 2006 (edited) I tryed to write a dll that enables autoit to do callback's and i realy wonder why it works Its a realy simple dll that forwards all 32bit pointers via WM_COPYDATA back to autoit i only tested it with 'EnumWindows' which is useless because autoit has WinList() but i have no idea what to test next. I didnt find (dont know) any interesting api's. Any ideas? -------------------- Updated: 05.08.06 CopyFileExA - Crashes autoit but copying works SetConsoleCtrlHandler - Works but only in a console CreateThread - Async stuff waits up to 60 seconds and fires unsorted Updated: 06.08.06 Other windows messages can be used to Commented Example "EnumWindows" function headers with DllCall Syntax in dll source Edited August 6, 2006 by piccaso CoProc Multi Process Helper libraryTrashBin.nfshost.com store your AutoIt related files here!AutoIt User Map Link to comment Share on other sites More sharing options...
/dev/null Posted August 2, 2006 Share Posted August 2, 2006 Any ideas?could you post the source of your DLL?CheersKurt __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
piccaso Posted August 2, 2006 Author Share Posted August 2, 2006 could you post the source of your DLL? oops, forgot...Added to first post.i Used Freebasic 0.17 CoProc Multi Process Helper libraryTrashBin.nfshost.com store your AutoIt related files here!AutoIt User Map Link to comment Share on other sites More sharing options...
Gerome Posted August 3, 2006 Share Posted August 3, 2006 Hi,I tryed to write a dll that enables autoit to do callback'sand i realy wonder why it works Its a realy simple dll that forwards all 32bit handles via WM_COPYDATA back to autoiti only tested it with 'EnumWindows' which is useless because autoit has WinList()but i have no idea what to test next.I didnt find (dont know) any interesting api's.Any ideas?A question please...Does AutoIT natively support callbacks without writing a 3rd party DLL or alike please ?Any sample ? Yours,(¯`·._.·[Gerome GUILLEMIN] [Freestyle Basic Script Language Author]·._.·´¯):: Full SETUP w. HELP ::FBSL official web siteA keyboard is infinitely better as a programming tool than a toaster... Link to comment Share on other sites More sharing options...
piccaso Posted August 3, 2006 Author Share Posted August 3, 2006 Hi,A question please...Does AutoIT natively support callbacks without writing a 3rd party DLL or alike please ?Any sample ?No, thats why i'm playing around with this...does anyone know...coud it be that LARGE_INTEGER is a 64bit value? CoProc Multi Process Helper libraryTrashBin.nfshost.com store your AutoIt related files here!AutoIt User Map Link to comment Share on other sites More sharing options...
Gerome Posted August 3, 2006 Share Posted August 3, 2006 Hi,No, thats why i'm playing around with this...Ha!May be I can send my C code to the AutoIT author to natively support Callback does anyone know...coud it be that LARGE_INTEGER is a 64bit value?YES ! Yours,(¯`·._.·[Gerome GUILLEMIN] [Freestyle Basic Script Language Author]·._.·´¯):: Full SETUP w. HELP ::FBSL official web siteA keyboard is infinitely better as a programming tool than a toaster... Link to comment Share on other sites More sharing options...
piccaso Posted August 3, 2006 Author Share Posted August 3, 2006 Hi,Ha!May be I can send my C code to the AutoIT author to natively support Callback that would be great CoProc Multi Process Helper libraryTrashBin.nfshost.com store your AutoIt related files here!AutoIt User Map Link to comment Share on other sites More sharing options...
Gerome Posted August 3, 2006 Share Posted August 3, 2006 Hi,that would be great The very code is in fact 10 lines of C and 6 of ASM Yours,(¯`·._.·[Gerome GUILLEMIN] [Freestyle Basic Script Language Author]·._.·´¯):: Full SETUP w. HELP ::FBSL official web siteA keyboard is infinitely better as a programming tool than a toaster... Link to comment Share on other sites More sharing options...
Valik Posted August 3, 2006 Share Posted August 3, 2006 No offense, but your 10 lines of C and 6 lines of assembly are useless to us. I know how to implement this functionality already. The 6 lines of assembly are probably pretty similar to what I already know we need. The rest of it is going to take far more than 10 lines of C(++) to correctly hook everything up in AutoIt. Link to comment Share on other sites More sharing options...
Gerome Posted August 3, 2006 Share Posted August 3, 2006 Hi,No offense, but your 10 lines of C and 6 lines of assembly are useless to us. I know how to implement this functionality already. The 6 lines of assembly are probably pretty similar to what I already know we need. The rest of it is going to take far more than 10 lines of C(++) to correctly hook everything up in AutoIt.If you want to correctly manage the whole thing + combinating results via Apicalls, i advise you to use some ASM to manage correctly your stack to avoid crash Yours,(¯`·._.·[Gerome GUILLEMIN] [Freestyle Basic Script Language Author]·._.·´¯):: Full SETUP w. HELP ::FBSL official web siteA keyboard is infinitely better as a programming tool than a toaster... Link to comment Share on other sites More sharing options...
Valik Posted August 3, 2006 Share Posted August 3, 2006 I am aware of that. I verbosely explained the details of implementing this to the other developers months ago. I know exactly what needs to be done and it's simply a matter of doing it when the time is right. Link to comment Share on other sites More sharing options...
Minion Posted August 3, 2006 Share Posted August 3, 2006 Valik, what's eating you? He made a valid contribution, and, rather than just saying that you didn't need it, you go the extra mile and completely shoot it down while bragging about your own skill. If you know exactly what needs to be done, that's all good, but don't be a dick. Link to comment Share on other sites More sharing options...
Valik Posted August 3, 2006 Share Posted August 3, 2006 Minion, a word of advice. If you don't like something I say, keep your word-hole shut about it. I'm not interested in listening to you state the same worthless crap a thousand other people have before. If I want to be a dick, that's my prerogative. Remember that in the future. Second, I never shot down his code. Shooting it down would say it doesn't work at all. I have no doubt his code does work. It doesn't work for us. That's simply stating a fact. Third, I'm not bragging about my skill. I am simply pointing out that at least one active developer already knows how to implement this functionality so further discussion or input on the subject is unnecessary. In this particular case, the active developer who knows how to do it happens to be me. Link to comment Share on other sites More sharing options...
Minion Posted August 3, 2006 Share Posted August 3, 2006 Oh noes! /fear the mighty Valik. Okay, you didn't shoot it down. You just cut off its wings. It still runs, but it will never be able to fly. NEVER FLY, MAN! I <3 you, Valik. Link to comment Share on other sites More sharing options...
VicTT Posted August 3, 2006 Share Posted August 3, 2006 picasso...It would be interesting to be able to intercept and stop a shutdown..I understand this could not be done without callback.. Quote Together we might liveDivided we must fall  Link to comment Share on other sites More sharing options...
piccaso Posted August 4, 2006 Author Share Posted August 4, 2006 Hi,The very code is in fact 10 lines of C and 6 of ASM could i have a look at it?well i defentely cant implement it into autoit but i would love to have a look...No offense, but your 10 lines of C and 6 lines of assembly are useless to us. I know how to implement this functionality already. The 6 lines of assembly are probably pretty similar to what I already know we need. The rest of it is going to take far more than 10 lines of C(++) to correctly hook everything up in AutoIt.Damn...picasso...It would be interesting to be able to intercept and stop a shutdown..I understand this could not be done without callback..maybe do you have an example or know where i can read more about it? CoProc Multi Process Helper libraryTrashBin.nfshost.com store your AutoIt related files here!AutoIt User Map Link to comment Share on other sites More sharing options...
piccaso Posted August 4, 2006 Author Share Posted August 4, 2006 picasso...It would be interesting to be able to intercept and stop a shutdown..I understand this could not be done without callback.. Didnt test this with Shutdown only Logoff but... This can be done without callback: $WM_QUERYENDSESSION = 0x11 $WM_ENDSESSION = 0x16 $hWndDummy = GUICreate("") $fTrigger = False GUIRegisterMsg($WM_QUERYENDSESSION,"_Msg") Func _Msg($hWndGUI, $MsgID, $WParam, $LParam) $fTrigger = True Return False EndFunc While 1 If $fTrigger Then $fTrigger = False MsgBox(0,"Shutdown","No you dont!") EndIf Sleep(250) WEnd CoProc Multi Process Helper libraryTrashBin.nfshost.com store your AutoIt related files here!AutoIt User Map Link to comment Share on other sites More sharing options...
Richard Robertson Posted August 4, 2006 Share Posted August 4, 2006 What is Freebasic? I am going to hazard a guess that it is similar in syntax to Visual Basic? Why does AutoIt really need callbacks though? I am having the same problem in figuring out what they would be needed for. Link to comment Share on other sites More sharing options...
piccaso Posted August 4, 2006 Author Share Posted August 4, 2006 What is Freebasic? I am going to hazard a guess that it is similar in syntax to Visual Basic?well its free, badly documented, and easyer to learn than c/c++Why does AutoIt really need callbacks though? I am having the same problem in figuring out what they would be needed for.i didnt find anything interesting in the win api (jet) but sqlite could be used better with callback... CoProc Multi Process Helper libraryTrashBin.nfshost.com store your AutoIt related files here!AutoIt User Map Link to comment Share on other sites More sharing options...
piccaso Posted August 5, 2006 Author Share Posted August 5, 2006 updated 1'st post CoProc Multi Process Helper libraryTrashBin.nfshost.com store your AutoIt related files here!AutoIt User Map Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now