I have a form split over several tabs which means the creation of some of the controls are deferred.
The problem is I am trying to load data into that form which means loading data into components which are yet to be created thus an exception is thrown.
Is there some way I can send a message to each page of a tabnavigator to cause the components to be created before loading data to them?
The only way I can think of at the moment is to cause the tabs to be automatically made the current tab when the form is loaded. This is a bit naff isn't it.
Appreciate any thoughts on this.
Thank you so much for that!
I've spend hours and hours googling lifecycles and trying all sorts - that definitely fixed it!
Setting creationPloicy="All" will solve the immediate issue, but it is insidiously dangerous. Deferred instantiation is generally a good thing since a slow starting appliction can make a bad user experience and that this the primary reason "auto" is the default. Disabling deferred instantiation is a bad habit to get into.
A better soulution is to use binding, or your own event mechanism, to load the data into the child views when they are instantiated.