Archived Forum Post

Index of archived forum posts

Question:

crypt: TChilkatCrypt2; does not resolve

Jul 31 '12 at 07:57

The ActiveX (CHILKATCRYPT2Lib_TLB) that I downloaded does not contain TChilkatCrypt2. In fact, it does not contain any Delphi classes. The file that I downloaded is CryptActiveX-9.3.1-win32.msi. I want to use ReEncode Where did I go wrong?


Answer

When using any ActiveX with Delphi, you must "import" the ActiveX component into Delphi. This generates the .dcr, and .pas wrappers. For example, after importing the ChilkatCrypt2.dll (i.e. "Chilkat Crypt"), you will find the following files in the C:\Documents and Settings\Chilkat\My Documents\RAD Studio\9.0\Imports\ directory:

CHILKATCRYPT2Lib_TLB.dcr
CHILKATCRYPT2Lib_TLB.pas


Answer

I'm not seeing the same problem. I imported in Delphi XE2 and it works fine:

...
// *********************************************************************//
// OLE Control Proxy class declaration
// Control Name     : TChilkatCrypt2
// Help String      : ChilkatCrypt2 Class
// Default Interface: IChilkatCrypt2
// Def. Intf. DISP? : No
// Event   Interface: _IChilkatCrypt2Events
// TypeFlags        : (2) CanCreate
// *********************************************************************//
  TChilkatCrypt2PercentDone = procedure(ASender: TObject; pctDone: Integer) of object;
  TChilkatCrypt2AbortCheck = procedure(ASender: TObject; out abort: Integer) of object;

TChilkatCrypt2 = class(TOleControl)
  private
    FOnPercentDone: TChilkatCrypt2PercentDone;
    FOnAbortCheck: TChilkatCrypt2AbortCheck;
    FIntf: IChilkatCrypt2;
    function  GetControlInterface: IChilkatCrypt2;
  protected
    procedure CreateControl;
...