ramadash Posted September 26, 2006 Share Posted September 26, 2006 ok I use GUIRegisterMessage on 2 script, they both run at the same time. the first time the first script is executed it works, the first time the second script is executed it works. but the 2nd time the first script is executed it dosent work and I am really starting to get clueless as the "why" it dosent work. the first script register: $CMD_CallWrapper = 10000 GUIRegisterMsg($CMD_CallWrapper, "CallWrapper" ) the second script register: $CMD_CallWrapper = 10002 GUIRegisterMsg($CMD_CallWrapper, "CallWrapper" ) it looks like the 2nd register overwrite the first one.. but message ID's are differents so I don't see why it would do this (I dont have much experience of windows messaging, not to say none at all). Also I was not able to test if the 2nd script receive message works the 2nd time because I need the first script to work in order for the 2nd one to start again. I also tryied to re-register the first script each time befor it start's but there was absolutly no difference at all. Any help would be very appreciated thanks you in advance. Link to comment Share on other sites More sharing options...
lod3n Posted September 26, 2006 Share Posted September 26, 2006 Could you change the name of the function CallWrapper in one of the scripts? [font="Fixedsys"][list][*]All of my AutoIt Example Scripts[*]http://saneasylum.com[/list][/font] Link to comment Share on other sites More sharing options...
ramadash Posted September 27, 2006 Author Share Posted September 27, 2006 indeed i will try this, I will post results tomorrow. If this work, then I would really like to know why. (curiosity) Link to comment Share on other sites More sharing options...
ramadash Posted September 27, 2006 Author Share Posted September 27, 2006 I tryied this and it dosent work. I would really like some hints im starting to get really pissed.. Link to comment Share on other sites More sharing options...
Uten Posted September 27, 2006 Share Posted September 27, 2006 Could you provide a more elaborate sample? My PostMessage sample seems to work with several scripts open at the same time (tried with 4). I'm using Autoit-v3.2.1.4 on w2k. Please keep your sig. small! Use the help file. Search the forum. Then ask unresolved questions :) Script plugin demo, Simple Trace udf, TrayMenuEx udf, IOChatter demo, freebasic multithreaded dll sample, PostMessage, Aspell, Code profiling Link to comment Share on other sites More sharing options...
lod3n Posted September 27, 2006 Share Posted September 27, 2006 Could you post the code? It's hard to guess. [font="Fixedsys"][list][*]All of my AutoIt Example Scripts[*]http://saneasylum.com[/list][/font] Link to comment Share on other sites More sharing options...
Sgraffite Posted September 27, 2006 Share Posted September 27, 2006 If I set this up correctly, the only time it wouldn't work for me is when it can't differentiate between the scripts. When both scripts had unique names it worked, even if both used $CMD_CallWrapper = 10000 and both had functions named CallWrapper(). I used these names to test: main.exe $mygui = GuiCreate( "myTest", 1, 1) main2.exe $mygui = GuiCreate( "cow", 1, 1) Hope this helps! 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