Get the number of attendance photo.
Device number
Number of attendance photo.
When iFlag is 0, get the number of all attendance photo, when iFlag is 1, get the number of
verify succeed photo, when iFlag is 2, get the number of verify failed photo.
Return True if it is successful, or return False.
None
/// <summary> /// Download attendance photo names from device. /// </summary> /// <param name="Flag">When iFlag is 0, delete all attendance photo, when iFlag is 1, delete the photos between sTime and eTime </param> /// <param name="IP"> Ip of device </param> /// <param name="Port"> Port of Device </param> /// <param name="MachineNumber"> Device Number </param> private void GetPhotoCount(int Flag, 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 phtoCount = 0; if (axCZKEM1.GetPhotoCount(MachineNumber, out phtoCount, Flag)) { MessageBox.Show("GetPhotoCoun,phtoCount:" + phtoCount.ToString(), "Success"); } else { axCZKEM1.GetLastError(ref idwErrorCode); MessageBox.Show("Operation failed,ErrorCode=" + idwErrorCode.ToString(), "Error"); } }
''' <summary> ''' Download attendance photo names from device. ''' </summary> ''' <param name="Flag">When iFlag is 0, delete all attendance photo, when iFlag is 1, delete the photos between sTime and eTime </param> ''' <param name="IP"> Ip of device </param> ''' <param name="Port"> Port of Device </param> ''' <param name="MachineNumber"> Device Number </param> Private Sub GetPhotoCount(Flag As Integer, Optional IP As String = "10.0.0.44", Optional Port As Integer = 4370, Optional MachineNumber As Integer = 1) 'Create Standalone SDK class dynamicly. Dim axCZKEM1 As zkemkeeper.CZKEMClass = New zkemkeeper.CZKEMClass() axCZKEM1.Connect_Net(IP, Port) Dim idwErrorCode As Integer = 0 Dim phtoCount As Integer = 0 If axCZKEM1.GetPhotoCount(MachineNumber, phtoCount, Flag) Then MessageBox.Show("GetPhotoCoun,phtoCount:" & phtoCount.ToString(), "Success") Else axCZKEM1.GetLastError(idwErrorCode) MessageBox.Show("Operation failed,ErrorCode=" & idwErrorCode.ToString(), "Error") End If End Sub