Ford's Garage

Small garage of one Ford in the big internet


Extract icon from exe



Add-Type -AssemblyName System.Drawing
$icon = [System.Drawing.Icon]::ExtractAssociatedIcon("C:\path\to\file.exe")
$bitmap = $icon.ToBitmap()
$bitmap.Save("C:\path\to\icon.ico", [System.Drawing.Imaging.ImageFormat]::Icon)