Your time (...) blocks the user interface thread, so the child form will never receive messages and will not be loaded.
To achieve the goal, you must subscribe to the Load event and continue your code in the handler.
void Click() { var tempFrm = new dialogForm(); tempFrm.Load += frmLoad; tempFrm.Show(); } void frmLoad(object s, EventArgs ea) {
source share