Hi!
After converting our project from .net framework 1.1 to 2.0, we encounter a
probable bug while using and manipulating icons loaded from an embedded
resource. The following code can be used to reproduce the behaviour:
Stream Input = typeof(Form1).Assembly.GetManifestResourceStream("Icon.ico");
Icon Icon= new Icon( Input );
Icon.ToBitmap(); // throws an AccessViolationException
The icon file contains one icon with the dimensions 24 x 16 pixel. With
square icons everythings works as it should.
You can also crash visual studio 2005: Just try to load the icon file into
the resource designer. If the first (or only) icon inside the file is 24 x 16
pixel, the studio will crash.
Is this a known bug? When will a fix be available?
We are using .net framework 2.0 with hofixes KB917283 and KB922770,
Visual Studio 2005 with SP1, Windows XP SP2
With .net framework 1.1 the same code works correctly.
Regards,
Michael Zimdars
|