Howdy Xojonauts!
I am new to Xojo… But I am very interested in the cross-platform abilities, so I have taken the plunge…
Would someone please test (and, if possible, explain) the following?
Create a new, empty project.
Rename “Window” to “Main” and Inherit from the Window Class.
In the Inspector under “Behavior”:
set ImplicitInstance to False (Off)
set Visible to False (Off)
In App, add a Property named “StartWindow” with Super of “Main”.
In App, add an Open() event handler.
In the Open() event, add this code:
StartWindow = New Main
StartWindow.Show
Run the application.
According to the documentation (http://documentation.xojo.com/index.php/Window.ImplicitInstance) shouldn’t this be generating an error? Why does the window get displayed?
In the App.Open() event, add this code BEFORE StartWindow.Show():
StartWindow.Title = "Hello, world"
Why doesn’t the Title change? What am I not understanding?
In the Main class, add an Open() event handler and add this code to it:
System.DebugLog("Main.Open()")
Why does Main.Open() get called twice?
I come from a C/C++/C# background where we pass references around and create new windows on the fly all the time. Why is this behavior different?
Thanks for your help!
jdb