People, I found that CFileDialog class causes serious problem. I had a large free memory block in the address space of my prog: 1200 MB Then I create CFileDialog and delete it: CFileDialog *pdlg=new CFileDialog(TRUE); pdlg->DoModal(); delete pdlg; I check address space again and found only 700 MB: The reason was very simple: I found some dlls in the address space of my process like urlmon.dll, netapi.dll, modemInst.dll and so on. These dlls was loaded into my address space by CFileDialog class and was not unloaded by its destructor. As a result, I couldn't allocate memory for a large file- address space had been fragmented. Any idea how to solve this situation? I think to create CFileDialog in a separate process. May be, there are better variants?