side-by-side error

I have a win32 application that is developed on VB 2008 using WinAPIs. The project configuration is Active(Debug) while platform is Active(win32).
When I tried starting the application on another laptop, I got the following error:

Activation context generation failed for "..\MyApplication.exe". Dependent Assembly Microsoft.VC90.DebugCRT, processorArchitecture="x86", publicKeyToken="1fc8b3b9a1e18e3b", type="win32", version="9.0.21022.8" could not be found. Please use sxstrace.exe for detailed diagnosis.

Then I installed Microsoft Visual C++ 2008 Redistributable Package (x86) but with no result. I am still getting the same error. I think this is because the above Redistributable Package doesn't cover the DebugCRT.

Any idea!!
Ahmad
The very first thing I do on every C++ project I start if I'm using Visual Studio in its various versions is delete all Debug Build configurations (I don't use debuggers) and set the linker to link statically with LIBC. That would be the /MT linker switch. In that way I avoid having to use Setup programs for installation of my executables on another computer, as all the required support routines are contained within the single exe.

But to answer your question directly, try doing a release build and see if that solves the problem. If it does, then your supposition is likely correct.
Thanks for your update. Actually I had tried several ways to resolve the issue but with no clue.
I tried to build the project with release but I lack the know how to do that.

Thanks
Ahmad
Sometimes it helps to create a new project and copy the needed files over. In this way you should have the right settings.
Those kind of errors occur a lot, especially in c++. I recommend to try and avoid them as they can arm you a lot afterwards. Sometimes Creating the project all over and copying the information works. Anyway, I recommend learning how to avoid those errors. Of course, you can always use some programs such as checkmarx or others. But it is recommended to do it also on you own.
Good luck!
Ben.
This is a very simple error, it says right there that the DLL isn't found. Your second system either doesn't have the correct MSCRT installed or the directory they are installed to isn't in your PATH environment variable.
Last edited on

I think this is because the above Redistributable Package doesn't cover the DebugCRT


And why should it? The most fundamental idea about app development is that you try to get it right on your development computer before distributing the app to other folks to run on their computers. So you need to produce debug builds on the development box - not for distribution to end users. Before you proceed much further I'd recommend you learn how to set up your development environment so that you can produce debug/release builds as needed.
Topic archived. No new replies allowed.