When I want to display a form (C #) by clicking a button in another form, I usually create an object from the form I want to show and use the show method:
Form2 f2 = new Form2();
f2.Show();
or I work with the "Owner":
Form2 tempForm = new Form2();
this.AddOwnedForm(tempForm);
tempForm.Show();
the two methods generate the same results, but what is the best and what are the differences between them?
source
share