Vinod Singh

Vinod Singh

  • NA
  • 57
  • 0

Sytem.OutofMemoryException and System.InvalidOperaionException

Mar 20 2009 9:28 AM

Hi All,

I am getting   exceptions System.OutOf MemoryException and System.InvalidOpenrationException on the ShowDialog () method ,when i open the dialog multiple times in succession in the following code snipet.

frmTest frmTestDlg = new frmTest (arrList, "StrTitle");

DialogResult dlgResult=frmTestDlg .ShowDialog(this);

bool b1 = frmTestDlg .propB1;

.

.

frmTestDlg .Close();

frmTestDlg .Dispose();

The same exception falls on the Main() method of the program.

though i m disposing and setting null  dialog every time i open  plz help me ..

many thanks in advance...