BrockLanders
Programmer
Hi, I'm trying to do a simple OnCurrent event using Access 2000, but to no avail. The code is suppossed to pop up a messagebox if the current record is new. I have the below code saved as a module:
I then created a RunCode macro with NewRecordMark("frmOrders") in the Function Name box of the macro builder. Then I set the OnCurrent event of frmOrders to my macro.
When the form is opened I get the error: "The expression you entered has a function name that Access can't find."
It seems like just a simple syntax error, but I can't figure it out.
Thanks in advance for any help
Code:
Sub NewRecordMark(frm As Form)
Dim intnewrec As Integer
intnewrec = frm.NewRecord
If intnewrec = True Then
MsgBox "You're in a new record."
End If
End Sub
When the form is opened I get the error: "The expression you entered has a function name that Access can't find."
It seems like just a simple syntax error, but I can't figure it out.
Thanks in advance for any help