public static void SaveAsIcon(
this Image image,
Stream stream,
bool forceUncompressedResult = false
)<ExtensionAttribute>
Public Shared Sub SaveAsIcon (
image As Image,
stream As Stream,
Optional forceUncompressedResult As Boolean = false
)public:
[ExtensionAttribute]
static void SaveAsIcon(
Image^ image,
Stream^ stream,
bool forceUncompressedResult = false
)[<ExtensionAttribute>]
static member SaveAsIcon :
image : Image *
stream : Stream *
?forceUncompressedResult : bool
(* Defaults:
let _forceUncompressedResult = defaultArg forceUncompressedResult false
*)
-> unit The image can be saved even without a registered Icon encoder in the current operating system.
If the saved image is reloaded by the Bitmap(Stream) constructor, then it will have always Format32bppArgb pixel format. The indexed and 24 BPP pixel formats are preserved though if the saved stream is reloaded by the Icon(Stream) constructor.
On non-Windows platforms reloading the large icons can be problematic.
| ArgumentNullException | image or stream is . |