Container Control - Open Event

Is it possible that by calling Resize, it then keeps calling Resize? I’ve made that mistake many a time. Solved it by putting in a variable to check if Resized has been called and if so then I don’t call it again…

[quote=414182:@Dave S]I created a custom control using a Container Control to hold all the bits.
To the CC I added Open and Resize events…
The Resize event is called as desired… but the Open event is NEVER called… I even put breakpoints to be sure.
If I add an Activate event… it is called, but not the Open…

Constructor method is called, so maybe I will use that unless someone can tell me I did something wrong :([/quote]

A containers open event only fires when it’s embedded unless it’s an instance placed on a layout at design time.

this is what it is

I created the Custom Control… drag it to the window, run the app

guess next step is to clone the project, and start removing CP varaibles to see if it “works” again at some point, then reverse that process

well spoke too soon… that was the issue that caused the hang up… but not what aborted the OPEN events…

Dave,

Here’s the case I was thinking of. It turns out that for multiple instances of the same object (ie: control array), that Open fires before the constructor on each new item.

<https://xojo.com/issue/26254>

Maybe this is similar to your problem?