The purpose of my new database is customer queries. This is for our Customer Support rep, who when she recieves a query from a customer, passes it on to the relevant department, via email, to deal with it.
I have a module which has the code to create a new Email. This works, I can get Access to make Outlook start a new mail.
The database has all the possible recipient addresses in a table, and I have a subform within my "QueryEntry" form which automatically works out what email address the query should be sent to, and displays said address in a field on the subform. So, the recipient address is displayed in an open form at the moment of email-sending.
What I need is for the automated email to pick up this recipient from the form, and enter it automatically into the "To" field on the email.
In the code, I have these lines (amongst many others):
What would I need to replace "Recipient" and "QueryText" with to make these items get picked up from an open form on the screen?
Can it be done this way?
I hope that makes sense. I'm still an Access Novice so please be gentle.
Thanks.
I have a module which has the code to create a new Email. This works, I can get Access to make Outlook start a new mail.
The database has all the possible recipient addresses in a table, and I have a subform within my "QueryEntry" form which automatically works out what email address the query should be sent to, and displays said address in a field on the subform. So, the recipient address is displayed in an open form at the moment of email-sending.
What I need is for the automated email to pick up this recipient from the form, and enter it automatically into the "To" field on the email.
In the code, I have these lines (amongst many others):
With objMsg
.To = "Recipient"
.Subject = "New Query"
.Body = "QueryText"
.Importance = olImportanceHigh
What would I need to replace "Recipient" and "QueryText" with to make these items get picked up from an open form on the screen?
Can it be done this way?
I hope that makes sense. I'm still an Access Novice so please be gentle.
Thanks.