Saranga
Saranga

Reputation: 520

delete user from zk attendance device using c# api

I have set of ZK attendance device that using static IP address. I'm enrolling users to this machines using zkmkeeper.dll in C#. now i want to delete old users from these machines using system. I can't find the function to delete users, but there is function to disable. I want to delete that users permanently from devices.

Upvotes: 0

Views: 3302

Answers (4)

Ahmed Bamba
Ahmed Bamba

Reputation: 1

The way I found works for me. Use the SSR_deleteEnrollData function with only 3 parameters (while notice asks for 4 parameters)

SSR_deleteEnrolData(dwMachineNumber , dwEnrollNumber , dwBackupNumber)

Maybe depends of device version.

Upvotes: 0

Saranga
Saranga

Reputation: 520

After trying many ways I have finally found a way. clear all user data using axCZKEM1.ClearData(Convert.ToInt32(number), flag) and re enroll the data using Database.

Upvotes: 0

zafern
zafern

Reputation: 29

@Yuuuucef, thank you for reference. According to documentation

5.2.4.3 DeleteEnrollData
    VARIANT_BOOL DeleteEnrollData(LONG dwMachineNumber, LONG dwEnrollNumber,
LONG dwEMachineNumber, LONG dwBackupNumber)

The values of dwMachineNumber and dwEMachineNumber must be the same

Upvotes: 0

Yuuuucef
Yuuuucef

Reputation: 71

I had a similar issue when deleting userInfo or enrolled data but i found a workaround

objCZKEM.DeleteEnrollData(machineId, userId, machineId, 12)

according to the documentation : 12 indicates deleting the user (including the fingerprints, card number and password).

Upvotes: 1

Related Questions