Hey guys and gals not quite sure if this is where I should put this, I'm running into a really weird problem that I have yet to encounter...atleast until now. I am using Microsoft Visual C++ and playing with a little toy project using windows forms.
Anyways I have an initial login form that is the first thing that launches, I decided to add a background image by selecting the the form and under properties pointing to BackgroundImage and selecting my .png file.
Now when I try and debug it is giving me the following pop up error:
An unhandled exception of type
'System.Resources.MissingManifestResourceException' occurred in mscorlib.dll
Then it goes on to say that it could not find any resources appropriate for the specified culture or the neutral culture.
So this makes me wonder, in C++/CLI do I need to have the image in the same directory as the project even though it is being stored in the resx file? Does Microsoft Visual C++ prefer JPG, Bitmaps or another image format for form backgrounds instead of PNG?
Now the image is showing up in the login.resx file and after getting the error it points me at the line of code:
this->BackgroundImage = (cli::safe_cast<System::Drawing::Image^ >(resources->GetObject(L"$this.BackgroundImage")));
I have tried all sorts of google searches for solutions but I'm still not coming up with anything concrete that seems to be working for me.
Anyone run across this problem and have a fix that actually works?