By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,390 Members | 1,550 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,390 IT Pros & Developers. It's quick & easy.

DLookup for E-mail

P: 1
I have a report I am needing to run and have it e-mailed to a specific person. Basically the report runs off a query that when ran it ask which Market I want to run. I enter in 415 for an example. Based on that answer I would like the macro to open the report, get it ready to send and then do an e-mail look-up based on the answer I provided (415) to send the report to the manager over that market.

I have the macro written to do everything except look-up the e-mail address and send. Here is what I have put in the TO: line of the macro under the SendObject settings:

DLookup("MEM e-mail","tblDiv1MEM","Market="&[qry - QS Recap].[Market])

So based on the answer to the "qry - QS Recap" I need it to use that answer and go to the "tblDiv1MEM" table to pull the "MEM e-mail" data and insert it in the TO: line in order to send. Hope this explains it enough, but here is the names and data needed…

Tables - tblDiv1MEM is where the e-mail addresses are found in the field called MEM e-mail
Query - In the Market field I have set it up to ask Which Market? In order to pull only the data needed
Report - The report rpt - QS Visit Recap is set up to generate off the above qry
Macro - The macro is set to open the report and prepare it for e-mailing. This is where the issue is……..


Any help would be appreciated!
Sep 7 '07 #1
Share this Question
Share on Google+
1 Reply


Scott Price
Expert 100+
P: 1,384
You did a good job explaining what you are trying to do, but I'm not sure where the difficulty lies? Does the DLookup that you have not work? If not what happens?

Regards,
Scott
Sep 8 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.