private void DoWork(FormStart formStart, Loaded loaded) { _documentServices.GetDocuments(); Global.isStartFirst = true; if (loaded.InvokeRequired) { loaded.BeginInvoke(new Action(loaded.Close)); } }