Automatic Email Reminders - Help! (1 Viewer)


New member
Dec 1, 2021
HI All,

I've created a simple training database through Access and I can't seem to get the automatic email reminders to work. I keep getting this message, see attached. What could it possibly be? If I set it to Public Function, then it says there is a "Compile Error: User-defined type not defined", If I select Private Function or just Function, then I get another error stating "The expression On Timer you entered as the event property setting produced the following error: Sub or Function not defined. *The expression may not result in the name of a macro, the name of a user-defined function or [Event Procedure], * There may have been an error evaluating the function, event, or macro." If anyone can help me get to the bottom of this, I would appreciate it. See attached for screen shots.


  • Access Compile Error_CVang.PNG
    Access Compile Error_CVang.PNG
    85.3 KB · Views: 330
  • Access Code Builder_CVang.PNG
    Access Code Builder_CVang.PNG
    108.3 KB · Views: 331
you must add in VBE references (alt F11) , menu TOOLS, REFERENCES,
add Microsoft Outlook object library.
Alternatively change the declarations in the code to use late binding e.g. Dim oOutlook As Object, oMailItem As Object
If you do that, the Outlook reference isn't needed

Or use CDO to send Email direct from Access so that Outlook isn't used
Thank you. I was able to get this one working. I truly appreciate your help.

Users who are viewing this thread

Top Bottom