From: kejo41 on
I have a general form that contains patient information. In this form I can
scroll through different exam dates for a particular patient. I need to be
able to open a second form (for editing) based on two criteria, patient ID
and exam visit date.

I have used open args before to open a form when only one criteria was being
passed, howeverm, I can't figure this one out. Any help would be appreciated.

Thanks.
From: PieterLinden via AccessMonster.com on
kejo41 wrote:
>I have a general form that contains patient information. In this form I can
>scroll through different exam dates for a particular patient. I need to be
>able to open a second form (for editing) based on two criteria, patient ID
>and exam visit date.
>
>I have used open args before to open a form when only one criteria was being
>passed, howeverm, I can't figure this one out. Any help would be appreciated.
>
>Thanks.

You're opening this from a button, right? Then in the button's click event,
you have something like

Sub cmdOpenSomeOtherForm_Click()
Dim strFilter as string
strFilter = "[PatientID]=" & Me.cboPatientID & " AND [ExamDate]=#" & me.
txtExamDate & "#"
docmd.OpenForm "MyForm",acNormal,,strFilter,acFormEdit,acWindowNormal
End Sub

--
Message posted via http://www.accessmonster.com