Пример #1
0
        private void ShowRecordFingerprint()
        {
            FingerPrint.GetSingleton().RemoveFingerprintEvent(Controls);
            var fingerForm = new FingerPrintForm();

            fingerForm.m_fingerPrintCallback = ReceiveFingerPrint;
            fingerForm.ShowDialog();
        }
Пример #2
0
        private void FingerPrintForm_Load(object sender, EventArgs e)
        {
            FormManager.GetSingleton().SetCurrentFocusForm(this);
            m_zkFprint = FingerPrint.GetSingleton().GetFingerprint();

            FingerPrint.GetSingleton().SetupFingerprintEvent(Controls, zkFprint_OnFeatureInfo, zkFprint_OnImageReceived, zkFprint_OnEnroll, zkFprint_OnCapture);
            //Console.WriteLine();
            // m_zkFprint.BeginCapture();
            // m_zkFprint.CancelEnroll();
            m_zkFprint.EnrollCount = 3;
            m_zkFprint.BeginEnroll();
            ShowMessage("Please give fingerprint regiss.");
        }
Пример #3
0
        public Form1()
        {
            InitializeComponent();

            // UsbNotification.RegisterUsbDeviceNotification(this.Handle);
            StorageManager.GetSingleton();
            m_zkFprint = FingerPrint.GetSingleton().GetFingerprint();

            // Custom Move title bar
            Application.AddMessageFilter(this);
            controlsToMove.Add(this.TitleBarPanel);
            m_instance = this;
            FormManager.GetSingleton().SetMainForm(this);
            FormManager.GetSingleton().SetCurrentFocusForm(this);
        }
Пример #4
0
        private void zkFprint_OnEnroll(object sender, IZKFPEngXEvents_OnEnrollEvent e)
        {
            //Console.WriteLine("zkFprint_OnEnroll 2");
            if (e.actionResult)
            {
                string template = m_zkFprint.EncodeTemplate1(e.aTemplate);
                FingerPrint.GetSingleton().RemoveFingerprintEvent(Controls);
                m_fingerPrintCallback(template);

                this.Close();
            }
            else
            {
                ShowMessage("Error, please register again.");
                MessageBox.Show("Error, please register again.");
                m_fingerPrintCallback("");
                this.Close();
            }
        }
Пример #5
0
 public void SetupFingerprint()
 {
     FocusToMainForm();
     FingerPrint.GetSingleton().SetupFingerprintEvent(Controls, zkFprint_OnFeatureInfo, zkFprint_OnImageReceived, zkFprint_OnEnroll, zkFprint_OnCapture);
 }