
Set Variable = Field Value
I want to set a variable to be equal to a record ID number so that I can
retrieve it in a different form. This is a piece of my code, when I debug,
I can see the correct value of the RecordID, but it's value does not get
assigned to my lngRecEdit variable. Do you know what I am doing wrong?
Thanks!
Static lngRecEdit as Variant
Set db = CurrentDb()
Set rec = db.OpenRecordset(strSQL)
lngRecEdit = rec![RecordID].Value