christos_n

Hi

I wrote a utility in managed c++ that links against some native c++ code. It works as expected on my machine (or other developer's machines)

However, when I test it on a machine without VS2005 installed, the assembly won't load. I get some error messages on the event viewer suggesting that I may be be picking up some VS libraries. (see below)

I have built my assembly against the release version of the native c++ libraries. So why am I picking up Microsoft.VC80.CRTMicrosoft.VC80.CRT Or am I having some other problem

Any ideas appreciated. Thanks!

========== EventViewer output:

Generate Activation Context failed for C:\Program Files\...\xxx_MCPP.dll. Reference error message: The operation completed successfully.

Resolve Partial Assembly failed for Microsoft.VC80.CRT. Reference error message: The referenced assembly is not installed on your system.



Re: Visual C++ General Assembly won't load at runtime

Bite Qiu - MSFT

you need to deploy visual c++ library to your target machine, see redistributing visual c++ files, there are also other options for deployment visual c++ application, (like run the vcredict.exe, or create a setup project)see chooing a deployment method.




Re: Visual C++ General Assembly won't load at runtime

christos_n

Thanks -- I have copied the c++ libraries to the target machine library folder as explained in http://msdn2.microsoft.com/en-us/library/ms235291(VS.80).aspx. This worked.

However, I noticed the c++ libraries and manifest were already in the target machine but in the executable folder. Is there any any way to set the path (or the libpath) so that they can be found without having to copy them (I am using XP Professional)

Thanks again for your lelp

Christos





Re: Visual C++ General Assembly won't load at runtime

Bite Qiu - MSFT

The application directory and several pre-defined sub-directory will also be searched by operating system when finding an assembly. Have a look at Assembly Search Sequence, and How the runtime locates Assemblies.






Re: Visual C++ General Assembly won't load at runtime

poppenwimmerherbert

christos_n wrote:

Hi

I wrote a utility in managed c++ that links against some native c++ code. It works as expected on my machine (or other developer's machines)

However, when I test it on a machine without VS2005 installed, the assembly won't load. I get some error messages on the event viewer suggesting that I may be be picking up some VS libraries. (see below)

I have built my assembly against the release version of the native c++ libraries. So why am I picking up Microsoft.VC80.CRTMicrosoft.VC80.CRT Or am I having some other problem

Any ideas appreciated. Thanks!

========== EventViewer output:

Generate Activation Context failed for C:\Program Files\...\xxx_MCPP.dll. Reference error message: The operation completed successfully.

Resolve Partial Assembly failed for Microsoft.VC80.CRT. Reference error message: The referenced assembly is not installed on your system.





Re: Visual C++ General Assembly won't load at runtime

poppenwimmerherbert

christos_n wrote:

Hi

I wrote a utility in managed c++ that links against some native c++ code. It works as expected on my machine (or other developer's machines)

However, when I test it on a machine without VS2005 installed, the assembly won't load. I get some error messages on the event viewer suggesting that I may be be picking up some VS libraries. (see below)

I have built my assembly against the release version of the native c++ libraries. So why am I picking up Microsoft.VC80.CRTMicrosoft.VC80.CRT Or am I having some other problem

Any ideas appreciated. Thanks!

========== EventViewer output:

Generate Activation Context failed for C:\Program Files\...\xxx_MCPP.dll. Reference error message: The operation completed successfully.

Resolve Partial Assembly failed for Microsoft.VC80.CRT. Reference error message: The referenced assembly is not installed on your system.





Re: Visual C++ General Assembly won't load at runtime

poppenwimmerherbert

christos_n wrote:

Hi

I wrote a utility in managed c++ that links against some native c++ code. It works as expected on my machine (or other developer's machines)

However, when I test it on a machine without VS2005 installed, the assembly won't load. I get some error messages on the event viewer suggesting that I may be be picking up some VS libraries. (see below)

I have built my assembly against the release version of the native c++ libraries. So why am I picking up Microsoft.VC80.CRTMicrosoft.VC80.CRT Or am I having some other problem

Any ideas appreciated. Thanks!

========== EventViewer output:

Generate Activation Context failed for C:\Program Files\...\xxx_MCPP.dll. Reference error message: The operation completed successfully.

Resolve Partial Assembly failed for Microsoft.VC80.CRT. Reference error message: The referenced assembly is not installed on your system.