Email Prompt

  • Thread starter Thread starter ladybug via AccessMonster.com
  • Start date Start date
L

ladybug via AccessMonster.com

I would like to create a button that sends an alert through email to another
user. This button will be at the bottom of a form. The alert is to prompt
the emailed user to open the database and review the entry that the initial
user created.
Any ideas?
 
I'm not an admin or anything but this is what i've done.
I'm currently looking for a way to automate the send of the prepared email
that is created.

In your OnClick event:

Me.ButtonName.HyperlinkAddress = "mailto: (e-mail address removed) .....

the following link will assist you with creating the mailto string.]

http://www.ianr.unl.edu/internet/mailto.html

Hope this helps.

Pip''n
 
Also the following will work: (use only the parts of the email message
that you need)

This assums the button name is command0.
If Outlook is NOT open when this is done, then the email simply goes
into the outbox.

==============================
Private Sub Command0_Click()
On Error GoTo Error_Handler

Dim objOutlook As Outlook.Application
Dim objEmail As Outlook.MailItem

Set objOutlook = CreateObject("Outlook.application")
Set objEmail = objOutlook.CreateItem(olMailItem)

With objEmail
.To = "(e-mail address removed)"
.CC = "(e-mail address removed)"
.BCC = "(e-mail address removed)"
.Subject = "Look at this sample attachment"
.body = "The body doesn't matter, just the attachment"
.Attachments.Add "C:\Test.htm"
'.attachments.Add "c:\Path\to\the\next\file.txt"

' next two only if the body is to include HTML

.bodyformat = 2 ' not necessary if no html this makes
it html
' 1 is text 2 is
HTML 3 is RTF
.htmlbody = Chr(13) & Chr(13) & _
"<body>" & _
"<Table>" &_
"<tr>" &_
"<td><b> Date: </b></td>" & _
"<td>" & Date & "</td>" & _
"</tr>" &_
"<tr>" &_
"<td></td>" & _
"<td></td>" & _
"</tr>" &_
" </Table>" &_
"</body>"

.Send
'.ReadReceiptRequested
'.Display ' to see the email have have user actually do the
send
' don't use the .Send if you are using
Display


'
End With

Exit_Here:
Set objOutlook = Nothing
Exit Sub

Error_Handler:
MsgBox Err & ": " & Err.Description
Resume Exit_Here

End Sub
===================================
 
Back
Top