TheFerrisFile
Registered User.
- Local time
- Today, 05:57
- Joined
- Jul 7, 2006
- Messages
- 16
I am not the most knowledgeable with coding and have limped my way along to even get this far.
I have a continuous form that shows all of the records that are open in the db. I have a button on the continuous form that opens the main form to the specific record located in the subform on the main form.
The code I am using works fine for opening up the main form, but it does not open up to the correct record in the subform.
Here's the code I'm using:
Dim strWhere As String
Dim rs As DAO.Recordset
strWhere = "[Main_ClaimNo] = '" & Me![Main_ClaimNo] & "'"
DoCmd.OpenForm "frm_Main"
With Forms!frm_task (this is my subform)
Set rs = .RecordsetClone
rs.FindFirst strWhere (this is where VB is getting caught up)
If rs.NoMatch Then
MsgBox "Not found"
Else
.Bookmark = rs.Bookmark
End If
End With
Set rs = Nothing
Any help would be greatly appreciated as I have to have this working by tomorrow evening.
Cheers!
I have a continuous form that shows all of the records that are open in the db. I have a button on the continuous form that opens the main form to the specific record located in the subform on the main form.
The code I am using works fine for opening up the main form, but it does not open up to the correct record in the subform.
Here's the code I'm using:
Dim strWhere As String
Dim rs As DAO.Recordset
strWhere = "[Main_ClaimNo] = '" & Me![Main_ClaimNo] & "'"
DoCmd.OpenForm "frm_Main"
With Forms!frm_task (this is my subform)
Set rs = .RecordsetClone
rs.FindFirst strWhere (this is where VB is getting caught up)
If rs.NoMatch Then
MsgBox "Not found"
Else
.Bookmark = rs.Bookmark
End If
End With
Set rs = Nothing
Any help would be greatly appreciated as I have to have this working by tomorrow evening.
Cheers!