LABRADOR Sample: Implements a Server with an Out-of-Proc Custom Interface and Compiler COM Support
This sample shows how to use ATL to implement an EXE server. The server allows creation of an object that supports two custom interfaces, defined in Labrador.idl. Compiler COM support is used to implement custom interfaces that perform nontrivial marshaling of a C-style array.
Compare this sample with the LABRADOR sample in the ATL directory.
This sample code is provided to illustrate a concept and should not be used in applications or Web sites, as it may not illustrate the safest coding practices. Microsoft assumes no liability for incidental or consequential damages should the sample code be used for purposes other than as intended.
Building and Running the Sample
If you are running Visual C++ Express Edition, you might need to install the Platform SDK before running this sample. For information on how to do this, see.
To build and run this sample
Open the solution labrador.sln.
On the Build menu, click Build Solution. Note that a compiler warning will occur because this sample uses the obsolete ATL class CComModule. Refer to the ATL version of this sample to see how to use CAtlExeModule.
Set labdriv as the startup project (right-click the project node and click Set as StartUp Project).
On the Debug menu, click Start Without Debugging.
This sample demonstrates the following keywords:
#import; _com_ptr_t; _com_error