?
Ich hab die sache nun rausgefunden!
Nur noch als Beispiel/Tipp/Etc.
// Gets the temp folder
WCHAR Path0[MAX_PATH] = {0};
GetTempPath(MAX_PATH, Path0);
// Create a temp file with the same extension
WCHAR Path[MAX_PATH] = {0};
GetTempFileName(Path0, L"EIT", GetTickCount(), Path);
PathRemoveExtension(Path);
PathAddExtension(Path, PathFindExtension(lpFileName));
CloseHandle(CreateFile(Path, GENERIC_READ, 0, NULL, CREATE_ALWAYS, 0, NULL));
// Get the icon index
SHFILEINFO sfi = {0}; ICONINFO ici = {0};
SHGetFileInfo(Path, 0, &sfi, sizeof(sfi), SHGFI_SYSICONINDEX);
DestroyIcon(sfi.hIcon);
// Get the system image list
HICON hIc;
IImageList* lpIl;
SHGetImageList(SHIL_EXTRALARGE, __uuidof(IImageList), (void**)&lpIl);
// Get the icon
lpIl->GetIcon(sfi.iIcon, ILD_TRANSPARENT, &hIc);
lpIl->Release(); // Muss noch testen ob nötig
// Remove the temp file
DeleteFile(Path);
// Create a new bitmap from the icon
pBmp = new Gdiplus::Bitmap(hIc);
// Set the size to 128x128
Gdiplus::Image* pImg = pBmp->GetThumbnailImage(128, 128);
delete pBmp;
pBmp = (Gdiplus::Bitmap*)pImg;
// Cleanup
DestroyIcon(hIc);