Hi
I have a form called: frmNewWork and a table tblNewWork which I use to create new jobs for then email the report to the relevant team member.
At the moment the Cmd has a fixed email address in which I type in the new email address I wish to send to.
On my form I have a drop down list with the team members details in including their email address which I then have displayed in a text box called: txtone.
The drop down list is called:TeamDetails
Am I able to add the selected email address into the cmd button code?
So the report is emailed to who ever I select in the drop down list providing an email address is present.
This is what I currently use:
Thank You
Private Sub Command181_Click()
Dim stDocName As String
stDocName = "Report"
DoCmd.OpenReport stDocName, acPreview, , "[ID] = " & Me.ID
DoCmd.SendObject acSendReport, "Report", acFormatPDF, "me@email.com.com", "myCC@email.com", "Report Breakdown", "Your Report has been attached."
End Sub
I have a form called: frmNewWork and a table tblNewWork which I use to create new jobs for then email the report to the relevant team member.
At the moment the Cmd has a fixed email address in which I type in the new email address I wish to send to.
On my form I have a drop down list with the team members details in including their email address which I then have displayed in a text box called: txtone.
The drop down list is called:TeamDetails
Am I able to add the selected email address into the cmd button code?
So the report is emailed to who ever I select in the drop down list providing an email address is present.
This is what I currently use:
Thank You
Private Sub Command181_Click()
Dim stDocName As String
stDocName = "Report"
DoCmd.OpenReport stDocName, acPreview, , "[ID] = " & Me.ID
DoCmd.SendObject acSendReport, "Report", acFormatPDF, "me@email.com.com", "myCC@email.com", "Report Breakdown", "Your Report has been attached."
End Sub