MainForm.FormShow being called before Application.Run
Posted on 2011-03-07
I have a Delphi project comprising several forms
The forms are created automatically at start up
My main form has a FormCreate and FormShow routine
For the past 6 weeks of development the Mainform.FormShow routine has not been triggered until all the other forms have been successfully created.
Something has changed (I am not sure what) in the last 2 hours, and now the MainForm.FormShow routine is being called immediately after the MainForm.FormCreate.
This causes me problems as the FormShow routine makes use of the other auto created forms.
The MainForm.FormShow call is being triggered by the TCustomForm.CMShowingChanged method (defined in unit Forms) which is triggered by message CM_SHOWINGCHANGED
What could be causing this to be triggered?
This is really causing me to pull my hair out - any thoughts appreciated.