The init() function is called before the creation of your widgets, immediately after the script starts and the creation of global variables. main() is called after the widgets creation.
Thus, when your script start, the order of execution is:
* creation and setting of global variables
* init() is called
* the *visible* widgets are created (not the ones that are hidden)
* main() is called
When you press the "Test" button the above sequence is also executed.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.