G
Guest
Below is the code I'm using to go to a specific record in another form the
relies on the same query that lstVisitComplications does. I want to be able
to dblClk on a specific record in the lstBox have the
frmVisitComplicationDetail open to that specific record. The code below
doesn't work. It opens the form but not to the specific record that was
dblClk'd in the listBox.
Thanks in advance for your help,
Robert
Private Sub lstVisitComplications_DblClick(Cancel As Integer)
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "frmVisitComplicationsDetail"
DoCmd.OpenForm stDocName, , , stLinkCriteria
stLinkCriteria = "[fldVisitComplicationsNo]=" &
Me.lstVisitComplications.Column(0)
End Sub
relies on the same query that lstVisitComplications does. I want to be able
to dblClk on a specific record in the lstBox have the
frmVisitComplicationDetail open to that specific record. The code below
doesn't work. It opens the form but not to the specific record that was
dblClk'd in the listBox.
Thanks in advance for your help,
Robert
Private Sub lstVisitComplications_DblClick(Cancel As Integer)
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "frmVisitComplicationsDetail"
DoCmd.OpenForm stDocName, , , stLinkCriteria
stLinkCriteria = "[fldVisitComplicationsNo]=" &
Me.lstVisitComplications.Column(0)
End Sub