//提取应用程序中的图标
CSttring m_strIcoPath = L"xx.exe";
CRect m_rcItem; //绘制区域
HICON hIcon = ::ExtractIcon(GetModuleHandle(NULL), m_strIcoPath, 0);
if (hIcon != NULL)
{
// HDC hDC = GetDc(m_hWnd);
Graphics graphics(hDC);
Bitmap bitmap(hIcon);
graphics.DrawImage(&bitmap, m_rcItem.left, m_rcItem.top);
DestroyIcon(hIcon);
//
}
c++提取应用程序中的图标(绘制图标ico)

最新推荐文章于 2025-08-02 16:47:35 发布
