简体   繁体   中英

Unload dll files from a MFC Program

I have a MFC program that even I close the program it does not get away and still shown in the task manager. When I look at the call stack I saw that some dll files are only loaded but not unloaded.

Is thee a way to make all the dll files unloaded when exit the program? So the exe will not be shown in the task manager.

I have declared some variables at top of the class:

vtkPoints *newPts = vtkPoints::New();
vtkPoints *newPtsSuction  = vtkPoints::New();     
CArray <double,double> ScalarValues_pressure;
CArray <double,double> ScalarValues_suction;
CArray <double,double> ScalarValues;

And add the values to them in another function and use the variables directly in another function.

The problem in first place is not DLL unloading. Your application freezes in a sort of dead loop or otherwise does not complete the termination properly. Having this fixed, the libraries will be unloaded automatically and the process will go, including from the task list.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM