|
-
Dec 5th, 2000, 10:12 AM
#1
Thread Starter
Addicted Member
Hi all,
I have created a custom search form where the user is asked to input the staff number and then select search. My problem is, how do I make the staff details form go to the record specified by the staff number in the search form. I have included the code from my search form. I am using SQL Server.
Private Sub cmdStaffSearch_Click()
Dim strCriteria As String
frmStaffSearch.Show vbModal
'define the search criteria
strCriteria = "[Number] LIKE '" & frmStaffSearch! txtBrigadeNumberSearch.Text & "'"
With rscmdStaffDets
.Find strCriteria
If .EOF Then
MsgBox ("Staff member not found please check the Staff Number entered")
End If
End With
frmStaffdets1.refresh
Unload Me
End Sub
Cheers
-
Dec 5th, 2000, 10:19 AM
#2
Fanatic Member
You could pick up the bookmark from the record found and then use the Move command with ADO.
Hope that helps,
P.
Not nearly so tired now...
Haven't been around much so be gentle...
-
Dec 5th, 2000, 10:33 AM
#3
Thread Starter
Addicted Member
Hi Paul, I am a little unsure what you mean do you have a simple example.
Cheers
-
Dec 6th, 2000, 03:48 AM
#4
Thread Starter
Addicted Member
Thanks Paul,
will give it a try.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|