C++ Programming
08-06-2011, 12:21 AM
Hi, dear all,
I have a C++ project created in VS2003, now I need to create another project based on it, but need VS2008.
I open this project from VS2008, and the system did some conversion for it.
After did some small change about it, the project can be built in VS2008, but when I run it, get exception.
For example, my application class named as XXXXXApp (file name is XXXXXApp.cpp), the resurece file name as XXXXXAPP.resx.
System::Resources::ResourceManager * resources = new System::Resources::ResourceManager(__typeof(SHXStiffLibNet::SHXStiffLibApp));
this->AppImageList->ImageStream = (__try_cast(resources->GetObject(S"AppImageList.ImageStream")));
the GetObject() call causes the error.
I open the .resx file and I can see the "AppImageList.ImageStream" node is there, but why cause exception?
Thanks!
I have a C++ project created in VS2003, now I need to create another project based on it, but need VS2008.
I open this project from VS2008, and the system did some conversion for it.
After did some small change about it, the project can be built in VS2008, but when I run it, get exception.
For example, my application class named as XXXXXApp (file name is XXXXXApp.cpp), the resurece file name as XXXXXAPP.resx.
System::Resources::ResourceManager * resources = new System::Resources::ResourceManager(__typeof(SHXStiffLibNet::SHXStiffLibApp));
this->AppImageList->ImageStream = (__try_cast(resources->GetObject(S"AppImageList.ImageStream")));
the GetObject() call causes the error.
I open the .resx file and I can see the "AppImageList.ImageStream" node is there, but why cause exception?
Thanks!