开发者

WIX: How to use the ComPlus action when the target DLL is written in .net 4?

I'm trying to convert a component from .net 3 to 4. The component has com interp functions that must be installed into a Component Services application. Current I'm using a WiX constructed install to do the w开发者_C百科ork via the Complus action. However, when the component is changed to .net 4 if just get invalid reference problems as it seems to use the wrong version of Enterprise Services. Looking around the web it seems that for your own custom actions you'd add a supportedRuntime to the actions config and link the config and dll together. However, I've no idea how to do this for an action that comes with WiX. Any ideas?


Actually the more I think about it, I believe the Complus action is a non-managed component that is invoked by non-managed code. Therefore there isn't an opportunity to use the config SxS idea. So looking at the code for the Complus action it's doing a fairly simple CoCreateInstance to create an instance of System.EnterpriseServices component. So the problem is that CoCreateInstance always creates a .net 2 version of the component, how do you get CoCreateInstance to invoke the v4? So far the only thing I've seen is to alter the registry for System.EnterpriseServices and tell it to always use 4 but that sounds a bit drastic. Heellllp....

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜