Custom image/icon issues

I'm currently building a UI with Windows Form Application. I have a second form opening when the user selects About from the Help menu. The problem is that if I put a PictureBox on this form. It builds fine, but when I run the program and click About it brings up an error message that says:

"Unhandled Exception has occured in your application. If you click Continue, the application will ignore this error and attempt to continue. If you click Quit, the application will close immediately."


Once I hit Quit and debug I get a message next to a line about the picturebox:

"An unhandled exception of type 'System.Resources.MissingManifestResourceException' occurred in mscorlib.dll

Additional information: Could not find any resources appropriate for the specified culture or the neutral culture. Make sure "CoD4RconTool.CoD4RconTool.Form2.resources" was correctly embedded or linked into assembly "CoD4 Rcon Tool" at compile time, or that all the satellite assemblies required are loadable and fully signed."


It breaks at this line of code:

this->pictureBox1->Image = (cli::safe_cast<System::Drawing::Image^ >(resources->GetObject(L"pictureBox1.Image")));

I'm guessing this has something to do with my Form2.resx file? I'm not sure if the file is in the wrong place, if it needs to be named a certain way, or if I need to reference it specifically somewhere.

Also, the same errors occur if I try to use a custom icon for the second forms title bar. I can use images and icons on the first form without a problem.

Any help is greatly appreciated!
Topic archived. No new replies allowed.