Hello,
I have problem to pass identity value from main form to other forms in Access 03 database. I am sure this is simple for most of you but I am stumped.
I have one main form BASELINE, and subsquent forms like FOLLOWUP, MEDICATIONS etc that need to carry over patient Id, initials to the subsquent forms. if record not in BASELINE, it not allowed in other forms.
The patient ID passed successfully, not initials didn't work, when i open the other form , it always showed Compile error Sub or Function not defined with FixMe highlighted
I have the following code:
Private Sub Form_Current()
If Not IsNull(Me.[HiddenPatN]) Then
Dim per As String
per = Me.[HiddenPatN].Value
Me.PN.Value = per
Dim vv As Variant
vv = DLookup("[Initials]", "Baseline", "[PTNTNM] = '" & per & "'")
Me.ini.Caption = FixMe(vv)
Else
Me.PN.Value = ""
Me.ini.Caption = ""
End If
End Sub
Any one could help me to fix the problem.
Thanks lot!