Previous in Contents Next in Contents

Using Visual C++

After modifying the client payment component (CPC) sample source files, you are ready to build your CPC DLL. The CPCPlugIn.dsw file is a Microsoft® Visual C++® makefile that you can use to build a sample CPC. If you use this makefile to build your CPC DLL, you must change all references to "cpcplgin" to the name of the payment method that you are building. It is recommended, however, that you let Developer Studio create a makefile for you by creating a new Developer Studio project workspace.

To create a new CPC
  1. Copy the files in the Simple directory to the directory in which you want to build your CPC.
  2. Modify the project dependencies that reference the Samples\Common directory.
  3. Edit the source files (including the .idl and .rgs files). Locate the places in the files that are marked // MOD TODO. These markers identify the places in the source files that need to be changed.
  4. Because comments are not allowed in the .rgs file, you must change the globally unique identifier (GUID) specified in that file to the coclass GUID that you specified in your .idl file. Additionally, change all references to "MyCPC" to the name of your CPC.
  5. Change the base address in the Project Settings/link options/Output. If this is the same as another component's base address it significantly slows down the load process.

If you encounter any problems creating your own version of this sample, or if you lack experience with Visual C++ 5.0, you can create a Component Object Model (COM) object by any means with which you are familiar. This object must implement ICreditCardEncryption2 and IPaymentProviderInstall.


© 1997-2000 Microsoft Corporation. All rights reserved.