windows service written in C++, COM objects, call from C#
C#
2
Posts
1
Posters
0
Views
1
Watching
-
How can I access the functions of a COM object located in a windows service? The windows service was written under Visual C++ 6.0. -Alma-
I have done it in the following way: 1. registered the service: MyService.exe /service 2. added the associated type lib to the project: using MyServiceLib; (I used the Add reference wizard: Solution explorer tab, right click on the solution name, click on Add reference..., click on COM tab, in the appearing list box select the needed type library) 3. Created an object: IMyObject newObject = new MyServiceLib.MyObjectClass(); 4. Called the objects methods: newObject.Function(param1, param2); -Alma-