Code Heaven For C# Developer

Saturday, April 9, 2011

Convert an image into icon...

This method will change an image into icon..

private Icon SetIcon(Image img)
{
Bitmap bmp = new Bitmap(img);
IntPtr Hicon = bmp.GetHicon();
Icon icon = Icon.FromHandle(Hicon);
return icon;
}

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]



<< Home