How to get the id of the match fingerprint? (uareu4500) vb.net

  • Thread starter Thread starter Buw_21
  • Start date Start date
B

Buw_21

Guest
What I've tried, my problem is that I dont know how to get the id of the match fingerprint and put it in the attendance

Public Sub OnCaptured(ByVal captureResult As CaptureResult)

conDB = New MySqlConnection
conDB.ConnectionString = "server=localhost;user id=root;password=;database=bam_records"
conDB.Open()
Dim adapter As New MySqlDataAdapter("SELECT * from student_records ", conDB)
Dim fingerds As New DataSet
Dim i As Integer

Dim adt = New MySqlDataAdapter("select * from student_records", conDB)
adt.Fill(fingerds, "student_records")




If Not _sender.CheckCaptureResult(captureResult) Then Return

SendMessage(Action.SendMessage, "A finger was captured.")

Dim resultConversion As DataResult(Of Fmd) = FeatureExtraction.CreateFmdFromFid(captureResult.Data, Formats.Fmd.ANSI)

If captureResult.ResultCode <> Constants.ResultCode.DP_SUCCESS Then
_sender.Reset = True

Throw New Exception(captureResult.ResultCode.ToString())

End If

thisfinger = resultConversion.Data

For Each fiv As Fid.Fiv In captureResult.Data.Views

SendMessage(Action.SendBitmap, _sender.CreateBitmap(fiv.RawImage, fiv.Width, fiv.Height))

Next


Dim thresholdScore As Integer = DPFJ_PROBABILITY_ONE * 1 / 10000
If fingerds.Tables("student_records").Rows.Count > 0 Then
For i = 0 To fingerds.Tables("student_records").Rows.Count - 1
Dim A As String = fingerds.Tables("student_records").Rows(i).Item(0)
Dim X = Fmd.DeserializeXml(A)
fpn.Add(X)
Next
End If
Dim identifyResult As IdentifyResult = Comparison.Identify(thisfinger, 0, fpn, thresholdScore, 1)
If identifyResult.ResultCode <> Constants.ResultCode.DP_SUCCESS Then
_sender.Reset = True
Throw New Exception(identifyResult.ResultCode.ToString())
End If
Dim sqlQuery As String = "INSERT INTO attendance(student_id,attendance_date)
VALUES ('" & >>>>> idhere & "','" & DateTime.Now.ToString & "')"
Dim sqlCommand As New MySqlCommand

With sqlCommand

.CommandText = sqlQuery
.Connection = conDB
.ExecuteNonQuery()
End With
MessageBox.Show("Recorded in the attendance")
SendMessage(Action.SendMessage, "Result Of The Identification " + identifyResult.Indexes.Length.ToString())
SendMessage(Action.SendMessage, "Place Index")
conDB.Close()
End Sub

Continue reading...
 
Back
Top