If you have the devenv.exe.manifest file installed you need to create
one for your application too.  IIRC this is the same error I was getting
before I created one for my application.

James Johnson

-----Original Message-----
From: dotnet discussion [mailto:[EMAIL PROTECTED]] On Behalf Of
Chris Sells
Sent: Tuesday, April 30, 2002 12:50 AM
To: [EMAIL PROTECTED]
Subject: [DOTNET] ImageLists and
System.Reflection.TargetInvocationException?!?

All of a sudden, when I build a WinForms app with a non-empty imagelist,
e.g. this sample [1], it throws a TargetInvocationException on the
following code inside of InitComponents:

this.imageList1.ImageStream =
((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList
1.ImageStream")));

The entire app was generated with the wizard and the designer. What
could cause such a thing? I've repaired my OS (WinXP Pro) and repaired
VS.NET. Any ideas before I remove and reinstall the runtime?

Chris Sells
http://www.sellsbrothers.com/

[1] http://www.sellsbrothers.com/samples/ImageListTest.zip

You can read messages from the DOTNET archive, unsubscribe from DOTNET,
or
subscribe to other DevelopMentor lists at http://discuss.develop.com.

You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.

Reply via email to