Link to home
Start Free TrialLog in
Avatar of TrinaD71
TrinaD71Flag for United States of America

asked on

Runtime Error 424 Object Required

I have a database that sends an automatic email.  Everything worked fine but I had to create a new database and reload the tables.  I lost one reference that I had to select again in VB in doing this.  It fixed one error.  I am now receiving an error that says 'Runtime 424 Object Required' when attempting to send the email (it worked fine before).  It stops on code that only calls the module which contains the connection to Outlook to send the email.  Is this a missing reference as well?  Do you know which one?  The code it stops on is:
                EmailModule.SendEmail ("Letter")
ASKER CERTIFIED SOLUTION
Avatar of Brian Mulder
Brian Mulder
Flag of Netherlands image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of TrinaD71

ASKER

I've added one to the Microsoft Outlook Object Library but it didn't help.  Are you talking about the Outlook sync type library?
I figured it out.  One letter in the name was the wrong case.  Duh Thanks!
Avatar of Guy Hengel [angelIII / a3]
>>Runtime Error 424 Object Required
at least 1 object variable has not got been assigned.

How is the variable EmailModule be declared, or is this the name of the VM Module?
Inside the Procedure SendMail, is there any error handling? if not, add the basics so the debug pointer will stop at the line where the error occurs inside the procedure... Also check how VB "breaks" when a error occurs, you should set this while debugging to "break at any error". When the code is somewhat stable, you can change this to "break on unhandled errors"

Cheers
well thank you! if it was in the name then outlook probably couldn't resolve the name
I'm sorry AngelIII, I didn't see your comment when I accepted Bruintje's answer.  I've written an email to ask how to award points and change a B to an A but I haven't heard back from them yet.  I'm going to search the community topics again today to see if I can figure it out.  I was quite sick yesterday so I'm hoping that the answer was right in front of my face and I can figure it out today so I can award my thanks.  Until then, thank you very much for your help.  I do truly appreciate it.
community support should be able to undo the accept so you can accept the answer from angelIII
you can post a 0 point question with your request here
https://www.experts-exchange.com/Community_Support/
Thanks.  I don't want to undo the accept from you though.  I thought that I could award points.  I'll go to the Community Support and ask to find out but you helped me as well so you deserve credit as well as my thanks.