提取exe文件的图标

  TIcon *pIcon = new TIcon();
  WORD wIndex;
  HICON hIcon=ExtractAssociatedIcon(HInstance,"c://windows//explorer.exe", &wIndex);
  pIcon->Handle =hIcon;
  Form1->Icon = pIcon;
  Image1->Picture = (TPicture *)pIcon;

你可能感兴趣的:(c,image,exe)