GetCardFun

Definition

Usage

Obtain whether the device supports the RF card.

Parameter

Device number.

Values:

1: The device supports only RF card verification.

2: The device supports both RF card verification and fingerprint verification.

0: The device does not support RFcard verification.

Return Value

Return True if it is successful, or return False.

Related Function

None

 

Ejemplo

C#

    /// <summary>
    /// Obtain whether the device supports the RF card.
    /// </summary>
    /// <param name="CommKey"></param>
    /// <param name="IP"></param>
    /// <param name="Port"></param>
    /// <param name="MachineNumber"></param>
    private void GetCardFun(string IP = "10.0.0.44", int Port = 4370, int MachineNumber = 1)
        {
    //Create Standalone SDK class dynamicly.
            zkemkeeper.CZKEMClass axCZKEM1 = new zkemkeeper.CZKEMClass();
            axCZKEM1.Connect_Net(IP, Port);
    int idwErrorCode = 0;
    int CardFun = 0;
    if (axCZKEM1.GetCardFun(MachineNumber, ref CardFun))
            {
                MessageBox.Show("The Device card fun is=" + CardFun.ToString(), "Success");
            }
    else
            {
                axCZKEM1.GetLastError(ref idwErrorCode);
                MessageBox.Show("Operation failed, ErrorCode=" + idwErrorCode.ToString(), "Error");
            }
        }

VB

    ''' <summary>
    ''' Make sure whether the machine supports the RF card function.
    ''' </summary>
    ''' <param name="IP"> Ip of device </param>
    ''' <param name="Port"> Port of Device </param>
    ''' <param name="MachineNumber"> Device Number </param>
    Private Sub GetCardFun_Click(Optional IP As String = "10.0.0.44", Optional Port As Integer = 4370, Optional MachineNumber As Integer = 1)
    Dim idwErrorCode As Integer = 0
    'Create Standalone SDK class dynamicly.
    Dim axCZKEM1 As New zkemkeeper.CZKEM
        axCZKEM1.Connect_Net(IP, Convert.ToInt32(Port))
    Dim CardFun As Integer
    If axCZKEM1.GetCardFun(MachineNumber, CardFun) = True Then
            MsgBox("The card fun is=" & CardFun.ToString(), MsgBoxStyle.Information, "Success")
    Else
            axCZKEM1.GetLastError(idwErrorCode)
            MsgBox("Operation failed,ErrorCode=" & idwErrorCode.ToString(), MsgBoxStyle.Exclamation, "Error")
    End If
    End Sub