Error in loading a DLL
I packed my VC application in release mode and tested in a clean Windows XP/2003. Once I run the application, it could not load my dll and reports the system error code 14001, which is 'ERROR_SXS_CANT_GEN_ACTCTX'. The api which returns the error is LoadLibrary
Can 开发者_如何学编程anybody help me out?
The problem was in side-by-side assemblies, clean Windows XP didn't have necessary assemblies, I think VC80.CRT or VC90.CRT (most probably). See about side-by side assemblies here.
You have 2 options to solve this issue: deploy assemblies with your application or build your application with static CRT libraries using /MT flag.
精彩评论