Greg

Greg

  • NA
  • 1
  • 0

Form cascades each time its created

Jun 10 2010 2:00 PM

Hi all,
I have a quick question.
Form1 creates Form2 when a button is pressed.
Form2 gets user input then closes.
Each time I launch Form2 it ignores the location setting and moves down and to the right slightly like it's a cascading window.
Can someone tell me what I've missed?
Thanks!
 
 
private
void openAddProjectDialog()
{
   Form2 f2 = new Form2();
   f2.SetDesktopLocation(100, 100);
   f2.ShowDialog();

   f2.Close();
   prjListView.Items.Add(f2.getPrjName.ToString());
}

Answers (2)