void CProcessBrowserDlg::LoadModules (DWORD dwProcessID) { HANDLE hSnapshot; BOOL bRet; MODULEENTRY32 meModuleEntry; hSnapshot = CreateToolhelp32Snapshot( TH32CS_SNAPMODULE,dwProcessID ); if( hSnapshot != NULL ) { meModuleEntry.dwSize = sizeof ( MODULEENTRY32 ); bRet = Module32First( hSnapshot,&meModuleEntry ); while( bRet ) { ………………………………. bRet = Module32Next ( hSnapshot,&meModuleEntry ); } CloseHandle( hSnapshot ); } }