When is the proper time to restore the UI layout settings of a System.Windows.Forms.Control?
I tried this:
FooBarGadget control = new FooBarGadget();
parent.Controls.Add(control);
control.FobnicatorWidth = lastLayoutSettings.FobWidth;
No cigar. Reason? control isn't finished laying out its internals; it's in its default size of 100x100 pixels after construction. Once it's done loading and actually displays in the UI, it will be 500x500 pixels. Therefore, setting the FobnicatorWidth to 200 pixels fails; it's larger than the control.
Is there a control.Loaded event - somwehere where I can restore my saved UI settings?