Jump to content
Sign in to follow this  
chaos945

GUIGetMsg while looping

Recommended Posts

I'm having trouble getting my GUI's to recieve events while looping. See attached examples.

OnEvent.au3 //example using OnEventMode 1

MessageLoop.au3 //example using loops

Working Example //example using loops, partially works

The working example will function correctly when the program in question is run before entering the loop. The terminate button functions in this case, but when Generating a new event it will not be recieved until the loop is over...

OnEvent.au3

MessageLoop.au3

Working_Example___Using_MessageLoops.au3

Share this post


Link to post
Share on other sites

I'm having trouble getting my GUI's to recieve events while looping.  See attached examples.

OnEvent.au3 //example using OnEventMode 1

MessageLoop.au3 //example using loops

Working Example //example using loops, partially works

The working example will function correctly when the program in question is run before entering the loop.  The terminate button functions in this case, but when Generating a new event it will not be recieved until the loop is over...

Each time you call GuiGetMsg you are getting a unique event from the queue. Your script is throwing away lots of events without checking what they were.

Share this post


Link to post
Share on other sites

If anyone is curious about resolving your GUI if you encounter something like this, I got it working with loops. Didn't get the Events working though.

I'd be interested in any comments on the efficiency of this code.

Working_With_Loops.au3

Edited by chaos945

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...