Código:
Begin
iMachineNumber:= 1;
iGLCount:= 0;
// Leemos los eventos en tiempo real
zk1.RegEvent(1,65535);
//Limpiamos los registros
// lvItems.Items.Clear;
// Deshabilitamos temporalmente hasta que obtengamos la info
// zk1.EnableDevice(1,False);
// Leemos los datos en memoria
if ZK1.ReadGeneralLogData(1) then
begin
while zk1.GetGeneralLogData(iMachineNumber, sdwEnrollNumber, idwVerifyMode, idwInOutMode, idwYear, idwMonth, idwDay, idwHour, idwMinute, idwSecond, idwWorkcode) do
begin
iGLCount:= iGLCount+1;
lvItems.Items.Add(IntToStr(iGLCount));
lvItems.Items.Add(IntToStr(sdwEnrollNumber));
lvItems.Items.Add(IntToStr(IdwVerifyMode));
lvItems.Items.Add(IntToStr(idwInOutMode));
lvItems.Items.Add(IntToStr(idwYear) + '-' + IntToStr(idwMonth) + '-' + IntToStr(idwDay) + ' ' + IntToStr(idwHour) + ':' + IntToStr(idwMinute) + ':' + IntToStr(idwSecond));
lvItems.Items.Add(IntToStr(idwWorkcode));
end;
end;
zk1.EnableDevice(1,true);
Código:
begin
// Conectamos el dispositivo
if ZK1.Connect_Net('192.168.3.201',4370) = true then
begin
Edit1.Text:= 'CONECTADO';
Edit1.Color:= clGreen;
Edit1.Repaint;
end
else
begin
Edit1.Text:= 'SIN CONEXIÓN';
Edit1.Color:= clRed;
Edit1.Repaint;
end;
end;
devolver true devuelve, pero, no lee un joraca