Originally the following code worked. I had 9 bitmaps loading as resources
and when I added bitmap 10 as an EmbeddedResource, the bitmap failed to load.
When I step through in the debugger, imageListBitMaps.Images.Count had a
value of 9. I suspect something with VS.NET is failed to recognize the new
bitmap and I think it had to do with the fact that one of my .resx files was
readonly due to Visual Source Safe.
Here is my code to load the bitmap images.
this.components = new System.ComponentModel.Container();
System.Resources.ResourceManager resources =
new System.Resources.ResourceManager(typeof(DatabaseScript));
this.imageListBitMaps = new System.Windows.Forms.ImageList(this.components);
this.imageListBitMaps.ColorDepth = System.Windows.Forms.ColorDepth.Depth8Bit;
this.imageListBitMaps.ImageSize = new System.Drawing.Size(17, 17);
this.imageListBitMaps.ImageStream =
((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageListBitMaps.ImageStream")));
Is there any way to get VS.NET to rebuild the resx file? I think that is my
problem, but of course I could be wrong.

Signature
Mark the Boro Dude
Senior Software Hack
joeycalisay - 14 Feb 2005 09:31 GMT
try Roeder's Resourcer:
http://www.aisto.com/roeder/dotnet/
Peek into the resx file if your desired image is there...

Signature
Joey Calisay
http://spaces.msn.com/members/joeycalisay/
> Originally the following code worked. I had 9 bitmaps loading as resources
> and when I added bitmap 10 as an EmbeddedResource, the bitmap failed to load.
[quoted text clipped - 13 lines]
> this.imageListBitMaps.ImageSize = new System.Drawing.Size(17, 17);
> this.imageListBitMaps.ImageStream =
((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageListBitM
aps.ImageStream")));
> Is there any way to get VS.NET to rebuild the resx file? I think that is my
> problem, but of course I could be wrong.