D
doyle60
I have the code below in the OnCurrent Event of a form to make a popup
form synch with the main form. It works very well---no problem. But
when I tried to add another pop up form to synch along as well---
copying the code below and just changing the name of the form---the
code failed.
It seems to me the code could be simpler too. How should the code
appear for two synched popups? Thanks in advance.
__________________________________
If IsOpen("QualityPerfTestEnlargefrm") Then
On Error GoTo Err_Command109_Click
Dim stDocName As String
Dim stLinkCriteria As String
Dim rsFind As Recordset
stDocName = "QualityPerfTestEnlargefrm"
stLinkCriteria = "[QID]=" & Me![QID]
DoCmd.OpenForm stDocName
Set rsFind = Forms(stDocName).RecordsetClone
rsFind.FindFirst stLinkCriteria
Forms(stDocName).Bookmark = rsFind.Bookmark
Exit_Command109_Click:
Exit Sub
Err_Command109_Click:
MsgBox Err.Description
Resume Exit_Command109_Click
End If
__________________________________________
Matt
form synch with the main form. It works very well---no problem. But
when I tried to add another pop up form to synch along as well---
copying the code below and just changing the name of the form---the
code failed.
It seems to me the code could be simpler too. How should the code
appear for two synched popups? Thanks in advance.
__________________________________
If IsOpen("QualityPerfTestEnlargefrm") Then
On Error GoTo Err_Command109_Click
Dim stDocName As String
Dim stLinkCriteria As String
Dim rsFind As Recordset
stDocName = "QualityPerfTestEnlargefrm"
stLinkCriteria = "[QID]=" & Me![QID]
DoCmd.OpenForm stDocName
Set rsFind = Forms(stDocName).RecordsetClone
rsFind.FindFirst stLinkCriteria
Forms(stDocName).Bookmark = rsFind.Bookmark
Exit_Command109_Click:
Exit Sub
Err_Command109_Click:
MsgBox Err.Description
Resume Exit_Command109_Click
End If
__________________________________________
Matt