Email troubles

lorenambrose

Active Member
Joined
Sep 17, 2008
Messages
265
OK here goes

My Engineering Request database needs an email feature

I have a seperate MACRO for each departments email address.


DEPARTMENT----------------ASSOCIATED EMAIL ADDRESS

Production -------- ------QAProduction@blah.blah
Engineering-------- ------QAEngineering@blah.blah
Materials---------- -------QAMaterials@blah.blah
Quality Assurance--- ----Quality Department@blah.blah

You get the idea


This is typical code for executing the email macro:

Private Sub Command23_Click()

If Me.Email = "Sent" Then
If MsgBox("Notification has already been sent. Do you wish to re-send?", vbYesNo, "Send Notification?") = vbYes Then
DoCmd.RunMacro "SendMail"
Else
DoCmd.Close
End If

Else
DoCmd.RunMacro "SendMail"
DoCmd.Close
End If

End Sub


Here is the problem. Right now the MACRO sends a PDF copy of the form that contains the button that executes the above code, which is what I want. However I need to be able to choose the receipient.

So if form "A" is open and that is the form I need to send as a PDF, I need to be able to choose a email receipient.

As it stands the MACROS contain the FORM NAME the RECEIPIENT. There is no real way to make the MACRO conditionally editable, SO.......................

<!--sizeo:4--><!--/sizeo-->So, what I am looking to do is this:<!--sizec--><!--/sizec-->

1. Place a button on all the forms that I want to email.

2. When clicked a form will open that acts as an address book / directory

3. When a button next to the desired receipient is clicked, outlook opens to the send screen addressed to the receipient chosen from the directory and attaches the form in step #1 as a PDF

4. User can now select "SEND" and off the message goes.


I have ZERO idea how to do something like this. I sure could use some help.

Thanks,
Loren
 

Excel Facts

Difference between two dates
Secret function! Use =DATEDIF(A2,B2,"Y")&" years"&=DATEDIF(A2,B2,"YM")&" months"&=DATEDIF(A2,B2,"MD")&" days"

Forum statistics

Threads
1,224,598
Messages
6,179,823
Members
452,946
Latest member
JoseDavid

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top