r/codeprojects • • Sep 14 '10

Universal COM Callable Wrapper which virtually ports any .Net class into any COM-compatible language. A ".Net Framework API", if you will. Open Source. Questions, comments, snide remarks?

http://code.google.com/p/corporate-overload/wiki/Universal_CCW
11 Upvotes

9 comments sorted by

View all comments

Show parent comment

1

u/[deleted] Sep 29 '10 edited Sep 29 '10

Theoretically. You should just be able to throw your C# project into the GAC as normal. Then, using CoCreateInstance‎ in C++ to 1) create the initial Universal_CCW_Factory COM object; 2) Use the Universal_CCW_Factory.New_Object("your assembly long name", "full.name.of.one.of.your.classes") method to begin working with one of your C# classes from within C++.

The only reason I say 'Theoretically' is because your C# classes would be directly handled by VB.Net code, but I guess it shouldn't matter. This is fully untested though. Isn't C# more or less easily portable into C++ (or visa versa) anyway, at least in Visual versions?