Navigation:  Implementing EasyGo > Add the LicProtectorEasyGo.dll to your project >

Using C++

Previous pageReturn to chapter overviewNext page

C++ needs header files. Depending on the compiler you use they can be automatically created.

 

First download the c++ sample you need from the FAQ area on our website

 

Find below how to add a DLL to Visual Studio C++

 

In Visual Studio right click on the project and Add a new class
Choose type "MFC class from TypeLib"
In the Class Wizard set "Add class from file" and select in "Location" the DLL you have just registered (e.g. <path>LicProtectorEasyGo251.dll)
Press Button ">>" to generate the class from the provided interface
Keep the Name (e.g. CLicProtectorEasyGo251.h) and press "Finish"
Now you have a file CLicProtectorEasyGo251.h in your project.
 
In file EasyGoDemoView.cpp sample modify the line using the latest version number

    #include "CLicProtectorEasyGo251.h"

 

In function CEasyGoDemoView::ProtectMe() adapt the lines

       CLicProtectorEasyGo251 licProtector;   // Licence Protector object

 

       // Create the automation object

       BOOL bRes = licProtector.CreateDispatch("LicenceProtector.LicProtectorEasyGo251");

          

Rebuild the project

 

 

The latest information about the ProgID, ClASSID, IID, LIBID can be found here.

 

As Licence Protector  is a COM server DLL it is used the same way you would integrate a Word automation. Just google for - Word Automation DLL C++ to find guides for different compilers.

 


Page url: http://www.helpserver.biz/onlinehelp/lp/easygo/2.5/help2000/index.html?using_c.htm