Delphi ActiveX组件中的验证指纹(DigitalPersona - FingerPrint)

时间:2013-08-12 07:29:17

标签: delphi fingerprint

如何在Delphi中使用DPFPVerification类,因为即使已导入activeX控件(DigitalPersona One Touch for Windows Control 1.0,它将安装类TDPFPVerificationControl和TDPPFEnrollmentControl)它也会成为错误'undeclare identifier'

实际上这与C ++和Visual Basic一起使用,但我需要使用Delphi 7。

步骤是:

  1. 安装One Touch DigitalPersona SDK,
  2. 从中导入ActiveX控件 德尔福7
  3. DPFPVerificationControl

    DPFPEnrollmentControl

    DigitalPersona One Touch SDK

    Manual Book (in VB & C++ ONLY, no Delphi Codes)

    VISUAL BASIC代码:

    // NOT ERROR, but error in Delphi ( var Ver:DPFPVerification; )
    Dim Ver As DPFPVerification  
    
    Private Sub Form_Load()
      ' Create DPFPVerification object.
      Set Ver = New DPFPVerification
    End Sub
    
    
    Private Sub DPFPVerificationControl1_OnComplete
    (ByVal Ftrs As Object, ByVal Stat As Object)  
    
      Dim Res As Object
      Dim Templ As Object
      ' Compare feature set with all stored templates.
    
      For i = 0 To 10
        ' Get template from storage.
        Set Templ = MainForm.GetTemplate(i)
    
        If Templ Is Nothing Then
        Else
          ' Compare feature set with particular template.
          Set Res = Ver.Verify(Ftrs, Templ)
          ' If match, exit from loop.
          If Res.Verified = True Then Exit For
        End If
      Next
    
      If Res Is Nothing Then
        Stat.Status = EventHandlerStatusFailure
        Exit Sub
      ElseIf Res.Verified = False Then
        ' If non-match, notify caller.
        Stat.Status = EventHandlerStatusFailure
        MainForm.Verified.Value = 0
      Else
        MainForm.Verified.Value = 1
      End If
    
      ' Show false accept rate.
      MainForm.FAR.Caption = Res.FARAchieved
    
    End Sub 
    

    DELPHI代码:

    uses
      Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
      Dialogs, OleCtrls, DPFPCtlXLib_TLB;
    
    var
      frm_verification: Tfrm_verification;
      Ver:DPFPVerification; << ERROR : 'undeclare identifier DPFPVerification'
    

    Two DigitalPersona Class

    DPFPCtlXLib_TLB.pas

0 个答案:

没有答案