Thanks for reporting this. You’re not missing anything - this is an embarrassing limitation in Objo Studio 26.7.2.
In this example, Window_Main refers to the window class, not the running window instance. Controls() and designer controls such as Canvas1 are instance members, so they cannot be accessed through Window_Main. The compiler message was technically correct, but Studio did not provide a clean way to reach the automatically created window instance.
This has been fixed for the next release: https://feedback.objo.dev/bug/770
Windows now have their own AppearanceChanged() event:
Event AppearanceChanged()
Canvas1.Refresh()
For Each child As Control In Me.Controls()
child.Refresh()
Next child
End Event
App.AppearanceChanged() remains available for application-wide state. It runs first, after which every open window receives its own AppearanceChanged() event.
I’ve also improved the compiler diagnostic so attempts to access instance members through a class name will now explain that a window instance is required.