Click here to Skip to main content
15,899,475 members
Home / Discussions / Visual Basic
   

Visual Basic

 
AnswerRe: Convert string "$0.67" to Number "0.67" Pin
EliottA20-Dec-08 6:59
EliottA20-Dec-08 6:59 
AnswerRe: Convert string "$0.67" to Number "0.67" Pin
Christian Graus20-Dec-08 10:39
protectorChristian Graus20-Dec-08 10:39 
AnswerRe: Convert string "$0.67" to Number "0.67" Pin
Gideon Engelberth20-Dec-08 14:20
Gideon Engelberth20-Dec-08 14:20 
QuestionDisable key Pin
Anup_Debnath19-Dec-08 22:34
Anup_Debnath19-Dec-08 22:34 
AnswerRe: Disable key Pin
Christian Graus19-Dec-08 23:38
protectorChristian Graus19-Dec-08 23:38 
GeneralRe: Disable key [modified] Pin
EliottA20-Dec-08 7:53
EliottA20-Dec-08 7:53 
AnswerCROSS POST Pin
dan!sh 20-Dec-08 10:43
professional dan!sh 20-Dec-08 10:43 
QuestionPrograming with digital Persona fingerprint reader Help !!!!! Pin
jayanta gogoi19-Dec-08 20:33
jayanta gogoi19-Dec-08 20:33 
Dear, Sir

I m Jayanta from Guwahati, India i start a program with Digital Persona Fingerprint reader its date reading section is success fully complete but its data storing section is disturbed a variable set problem if any body help me i will ever great full for all lige life.

my program code is

Dim cn As New ADODB.Connection
Dim WithEvents fpRegister As FPRegisterTemplate
Dim Template As FPTemplate 'Last template produced
Dim blob_read() As Byte
Dim blob_write() As Byte
Dim WithEvents fpGet As FPGetTemplate
Dim fVerify As FPVerify

Private Sub cmdExit_Click()
End
End Sub

Private Sub save_Click()
Dim rsUser As New ADODB.Recordset
Dim bVariant As Variant
Set fpGet = New FPGetTemplate

blob_write = ("FINGERPRINT")
bVariant = Null

If Template Is Nothing Then
MsgBox "Nothing Registered !!"
Exit Sub
End If
If txtUserCode = "" Then
MsgBox "Please enter UserCode", vbInformation
Exit Sub
End If
If txtUserName = "" Then
MsgBox "Please enter Username", vbInformation
Exit Sub
End If
Template.Export bVariant
blob_write = bVariant
rsUser.Open "select * from FP where ID='" & Trim(txtUserCode) & "'", cn, adOpenKeyset, adLockOptimistic
If rsUser.EOF Then
rsUser.AddNew
End If
rsUser!id = txtUserCode
rsUser!Name = txtUserName
rsUser!Fingerprint = blob_write
rsUser.Update
Set rsUser = Nothing
End Sub

Private Sub Form_Load()
cn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\FINGER.mdb;Persist Security Info=False"
optRegister_Click
End Sub

Private Sub Form_Resize()
Me.Width = 6345
Me.Height = 4410
End Sub

Private Sub fpGet_Done(ByVal pTemplate As Object)
Dim rsUser As New ADODB.Recordset
Set tp = pTemplate
Dim rp As FPTemplate

Set fpGet = New FPGetTemplate
Set fVerify = New FPVerify

Dim result As Boolean
result = False
rsUser.Open "select * from fp", cn, adOpenKeyset, adLockOptimistic
Do While Not rsUser.EOF
blob_read = rsUser("fingerprint")
varnt = blob_read
Set rp = New FPTemplate
er = rp.Import(varnt)
re = fVerify.Compare(rp, pTemplate, result, src, thsh, False, Sm_None)
If result = True Then Exit Do
Set rp = Nothing
rsUser.MoveNext
Loop

If result = False Then
MsgBox "User Fingerprint Not match !! you must register", vbInformation
Else
MsgBox "User Code : " & rsUser!usercode & vbNewLine & "User Name : " & rsUser!Name
cn.Execute "insert into logs(usercode,logtime) values ('" & rsUser!usercode & "',#" & Now & "#)"
End If
Set rp = Nothing
Set fpGet = Nothing
Set fVerify = Nothing
optRegister_Click
End Sub

Private Sub fpGet_SampleReady(ByVal pSample As Object)
pSample.PictureOrientation = Or_Portrait
pSample.PictureWidth = picFingerprint.Width / Screen.TwipsPerPixelX
pSample.PictureHeight = picFingerprint.Height / Screen.TwipsPerPixelY
picFingerprint = pSample.Picture
End Sub

Private Sub fpRegister_Done(ByVal pTemplate As Object)
lblStatus.Caption = ""
Set Template = Nothing
Set Template = pTemplate
Call SaveDetails
End Sub

Private Sub fpRegister_SampleReady(ByVal pSample As Object)

pSample.PictureOrientation = Or_Portrait
pSample.PictureWidth = picFingerprint.Width / Screen.TwipsPerPixelX
pSample.PictureHeight = picFingerprint.Height / Screen.TwipsPerPixelY
picFingerprint.Picture = pSample.Picture
lblStatus.Caption = "Sample ready"

End Sub

Private Sub optRegister_Click()
If optRegister.Value = True Then
lblStatus.Caption = "Before Putting finger on the sensor - Enter user details "
txtUserCode = "": txtUserName = "": picFingerprint.Picture = Nothing
txtUserCode.Enabled = True: txtUserName.Enabled = True
Set fpGet = Nothing
Set fpRegister = Nothing
Set fpRegister = New FPRegisterTemplate

fpRegister.Run
lblStatus.Caption = "Register: Press your finger in the device"
Else
lblStatus.Caption = "Press your finger in the device... "
txtUserCode = "": txtUserName = "": picFingerprint.Picture = Nothing
txtUserCode.Enabled = False: txtUserName.Enabled = False
Set fpRegister = Nothing
Set fpGet = Nothing
Set fpGet = New FPGetTemplate

fpGet.Run
lblStatus.Caption = "Verify: Press your finger in the device"
End If
End Sub

in the act of kindness kindly give me a solution !!!!!!

my email add is gogoi.jayanta@gmail.com

a lots of thanks.
AnswerRe: Programing with digital Persona fingerprint reader Help !!!!! Pin
Mycroft Holmes19-Dec-08 23:16
professionalMycroft Holmes19-Dec-08 23:16 
AnswerRe: Programing with digital Persona fingerprint reader Help !!!!! Pin
Christian Graus19-Dec-08 23:39
protectorChristian Graus19-Dec-08 23:39 
AnswerRe: Programing with digital Persona fingerprint reader Help !!!!! Pin
Wendelius20-Dec-08 10:45
mentorWendelius20-Dec-08 10:45 
QuestionSpecial Char in SQL Query Pin
Vineet Swami19-Dec-08 18:53
Vineet Swami19-Dec-08 18:53 
AnswerRe: Special Char in SQL Query Pin
Rajesh Anuhya19-Dec-08 19:09
professionalRajesh Anuhya19-Dec-08 19:09 
AnswerRe: Special Char in SQL Query Pin
Christian Graus19-Dec-08 19:18
protectorChristian Graus19-Dec-08 19:18 
AnswerRe: Special Char in SQL Query [modified] Pin
Wendelius20-Dec-08 0:28
mentorWendelius20-Dec-08 0:28 
QuestionProblem with regular expression Pin
shally_7919-Dec-08 18:32
shally_7919-Dec-08 18:32 
GeneralRe: Problem with regular expression Pin
Luc Pattyn20-Dec-08 2:02
sitebuilderLuc Pattyn20-Dec-08 2:02 
GeneralRe: Problem with regular expression Pin
shally_7922-Dec-08 17:46
shally_7922-Dec-08 17:46 
GeneralRe: Problem with regular expression Pin
Luc Pattyn23-Dec-08 0:07
sitebuilderLuc Pattyn23-Dec-08 0:07 
QuestionRun Process in background Pin
Gagan.2019-Dec-08 17:32
Gagan.2019-Dec-08 17:32 
AnswerRe: Run Process in background Pin
Christian Graus19-Dec-08 17:49
protectorChristian Graus19-Dec-08 17:49 
AnswerRe: Run Process in background Pin
Rajesh Anuhya19-Dec-08 19:15
professionalRajesh Anuhya19-Dec-08 19:15 
GeneralRe: Run Process in background Pin
Christian Graus19-Dec-08 19:19
protectorChristian Graus19-Dec-08 19:19 
GeneralRe: Run Process in background Pin
Rajesh Anuhya19-Dec-08 19:24
professionalRajesh Anuhya19-Dec-08 19:24 
GeneralRe: Run Process in background Pin
Gagan.2019-Dec-08 21:51
Gagan.2019-Dec-08 21:51 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.