Event Loop

My app seems to be experiencing an “Event Loop”, and I can’t seem to figure out where it’s coming from. I was wondering how I’d go about tracing back this error so I can fix it. If you need some information from me, let me know. Thanks for any help!

Not sure what you mean by “event loop”. Do you mean it just hangs? Or you get a cascade of events? Or what?

In the debugger window, under the “Stack”, I see “Event Loop” and my program completely stops working.

Is there an error message at the bottom of the screen? In the messages pane? If you press Resume, do you get an exception message?

That’s what’s weird; it’s an intermittent error that does not produce any type of exception message. I only see the “Event Loop” in the stack. I’ve tried to see if I can capture something in the “UnhandledException” area of the Session, but I still get nothing. When I push the resume or play button in the debugger window of Xojo, it keeps going without any exceptions. I should mention that this only happens whenever I close the page and re-open it.

What kind of app is it ? Console ? Desktop ? Web ?

Session would indicate Web.

What is in the app Open event ?

It’s a Webapp

Dim nRS As RecordSet // Declares a new RecordSet
Locations.DeleteAllRows // Safeguard against duplication in the case of refreshing
LocationFill // Refills the location window
uDBInt.query = “SELECT * FROM punch_info WHERE e_id=90001 AND InO=‘YES’” // Checks to see if person is clocked in
nRS = uDBInt.CollectRecordSet(uDBInt.ConnectToDB) // uDBInt.ConnectToDB connects to the database using SSL
// uDBInt.CollectRecordSet returns a RecordSet based on the query
If nRS.RecordCount > 0 Then // If the RecordCount is greater than one, that means the employee is punched in
func = “Out” // Using one control, its function is determined by the local variable “func”
ClockIO.Caption = “Clock Out” // Set the text
ClockIO.Style = buttonsSel // Set the style
Else
func = “In” //Same thing here
ClockIO.Caption = “Clock In”
ClockIO.Style = buttons
End If

ClockIO.ZIndex = 1 // Set the Zindex (I have a menu that slides out, and I want these two buttons behind it)
ManualLocation.ZIndex = 1

Are you sure this is App. Open ?

Looks to me like a lot of that UI stuff should go into Session.Open.

I fixed it! It looks like it had something to do with the WebCanvas Paint Event Handler. I was drawing my logos onto the page with a WebCanvas. I switched them over to ImageWells and that seemed to fix the problem entirely. Thanks for the input!