I have a parent form and a child form. I need to open the child form at the beginning of a method, do some pretty intensive tasks and then close the child form upon completion.
Here is basically what I've tried so far (with no luck):
Parent Form:
Child child = new Child();
Method()
{
child.ShowDialog();
//Method code here
child.CloseScan();
}
Child Form:
public void CloseScan()
{
this.Close();
}