Send Report From Access In A Body Of An E-mail

Dec 13, 2006

Could you please help me and advise if it's possible to send report from MS Access by mail - having report as a content of an e-mail instead of attachement?

View Replies


ADVERTISEMENT

General :: Bulk Mail Send With Different Mail Body Contents

Apr 26, 2013

I have a ms access table with two fields...tablename is ..."Addresses"..

Field1:= Employee_mail_id
Field2:= Leave_balance

What I need to do is that,I need to send individual mail (in Bulk) two each employee intimating their leave balances.
Is it possible to do it in vb .I want it to assign the codes in a button.

Below iss the code.

Dim r As Recordset
Dim email As String
Set r = CurrentDb.OpenRecordset("select * from Addresses")
Do While Not r.EOF
email = email & r(2) & ";"
r.MoveNext
Loop
r.Close
DoCmd.SendObject acSendNoObject, Null, Null, email, Null, Null, "Test subject", "Message body of the test letter", False, Null

View 2 Replies View Related

Send 'Report' To Mail Recipient

Aug 18, 2004

I am trying to send an MS Access 'report' as an attachment to a mail recipient in rtf format without success. Everything seems to work fine except the 'send' button. Click away and nothing happens.... no error messages, no nothing. Any suggestions or tips on how to make this work?

Thanks...

View 2 Replies View Related

VBA To Send Email From Access - Table Pasted In Message Body

Aug 11, 2011

I want to be able to send email and in the body i want the my table be pasted in email body...

Is that possible?

View 3 Replies View Related

Send Query In Email Body

Feb 27, 2006

I almost have what I need, but I am not quite there. I am a VBA novice and need help. I couldnt understand some of the code I have searched for on this topic.

I have a query that returns exactly the results I want. By using a SendObject macro I can accomplish sending the message with a .txt file attached. What I want to do is instead of having the attachment I want to send my query "FaxReportQueryReport" in the body of the email. No set address, just a set RE: line of "Today's Deliveries".

View 10 Replies View Related

Queries :: Pasting A Query In Outlook Mail Body

Jun 3, 2014

Is there a way to paste a access query result in the outlook message body?. I do not want to attach the query result in the email.

View 8 Replies View Related

Modules & VBA :: Add Field Values In Subject And Body Of Mail

Feb 4, 2014

I have a script that sends a mail using outlook to a different person depending on a value in a field. I want to add values from fields to the subject and body of the mail it creates. This is what I have so far:

Function Mail()
On Error GoTo Mail_Err
If (Forms![Manage Packages]![Customer] = "MSC") Then
DoCmd.SendObject , "", "", "email", "email", "", "[ID] - [Package Name] - Delivered", "Dear," & vbNewLine

[Code] .....

In the subject and body the field ID's I want to add are marked as [ID], [Package name] etc.

View 8 Replies View Related

Modules & VBA :: Send Two Reports In Email Body?

Jan 15, 2015

With the code below , I send the report: “ESERT4H”, in email body. How I could add yet another report on the same body of the email ?

DoCmd.OutputTo acOutputReport, "ESERT4H", "HTML(*.html)", "D:Access empESERT4H.html", False, "", 0, acExportQualityScreen
Dim Out As Outlook.Application
Dim NS As Outlook.NameSpace
Dim Folder As MAPIFolder
Dim Mens As MailItem

[Code] ....

View 7 Replies View Related

Access 2010 - VBA Code - Add Report To Body Of Email?

Feb 25, 2013

Access 2010 - add report to body of an email

i have VBA code to create an email and attach an excel file, what i would like is code to add a report called REPORTMISSINGDATES to the body of the email.

this is the code i have so far, which works and adds everythng i wqant except the main body of the email.

Private Sub Command31_Click()
On Error GoTo Command31_Click_Err
Dim Email As String
Dim name As Variant
Dim EMPloy As Variant
Dim month As Variant
month = MonthName([Forms]![STAFFATTENDANCEMenu]![StaffMonth])
EMPloy = Forms!staffattendancezone!Staff
name = DLookup("[STAFFNAME]", "[QRYSTAFFNAME]", "[ASA] = Forms!staffattendancezone!Staff")
Email = (Forms!STAFFATTENDANCEAdjust!Email)
DoCmd.SendObject acQuery, "STAFFATTENDANCEZONECheckEmployee", "ExcelWorkbook(*.xlsx)", [email], "", "", "" & "Attendance Errors", "THIS IS WHERE I WANT THE REPORT TO GO" _
End Sub

View 1 Replies View Related

Forms :: Using HTML To Format Body In Send Object Method?

Jun 26, 2014

Can I use html to format the message body in send object method ? If I can, how to do that.

View 5 Replies View Related

Modules & VBA :: Send Query Results In Table In Body Of Email

May 24, 2014

I have created some code to get the records of a query and it puts them in the body of the email but it doesn't format it well for example the email looks like

James | halliwell | 31
Leanne | smith |27
Alexis | smith |8

I would like it to be in a table is this possible,

Code:
Public Function SendEmail()
Dim MyDB As DAO.Database
Dim rst As DAO.Recordset
Set MyDB = CurrentDb

[Code] .....

View 3 Replies View Related

Modules & VBA :: Subform In Continuous Records Format - Send Contents Into The Body Of Email

Nov 10, 2014

I have a subform in Continuous Records format (records displayed are determined by controls on the parent). I would like to create a button that prepares an email and copies the contents of that subform in to the body of an email message.

The email. I have a method to create a new email, set To, CC, Subject and even Message Text.

Code:
strTo = txtName
strCC = txtManager
strSubject = "Something"
strMessage = "Hi, please find below list of details from X Y and Z" & vbnewline & vbnewline

That all works. Thats fine

The Records: I have found ways to have them added as an attachment, either the the SendObject and OutputTo method but I would like the list of records to be converted to a text string so I can include it within my strMessage variable, not include it as an attachment.

Code:
strMessage = strMessage & "Subform Records to go here"...

View 7 Replies View Related

Send Mail Automateclly

Feb 19, 2006

I send mail massage with the code
DoCmd.SendObject , , , strToField, , , strSubject, strMessage, False


and the access ask me the file attach

how can I send automateclly with no msgbox

View 3 Replies View Related

E-mail Send Via A Form

May 12, 2005

I would like to have a button on a form, against each record that has been entered onto the form and once the button has been clicked on, an e-mail would be automatically be generated with the contents of particular fields and automatically sent to a pre designated e-mail address.

Is this possible, if so and help would be most appreciated.

Many thanks in advance

View 5 Replies View Related

Only Send A Specific Record Via E-mail

May 13, 2005

I am trying to use the cmd.sendobject to send an e-mail to a specific e-mail address after clicking on a button on a form.

This works fine but send all the records within a form or report but I would only like to send a specific record not all of them.

The form is a continuous form.

Many thank in advance!.

View 2 Replies View Related

Send Mail Merge With Attachment

Sep 20, 2006

I have been searching the forums about how to send an email using a mail merge Word document with attachments and have not found a way to accomplish this. There are numerous posts on haw to send email using the SendObject function with attachments but I really need to use a Word mail merge to satisfy the requirements set forth by my superiors.

The database uses a query to pull the list of recipients. The query contains the name, email address and a few other informational items that need to be put in mail merge. I also need to attach a second 5 page Word document. At this point, I dont care if I have to deal with the Outlook security or not, I only have about 20 a day to send but if there is a way to get around it, that would be cool.

Would it be possible to create a Report that looks the same as the mail merge document and send it to each of the recipients from the query and attach the document to that email?

I am running up against a deadline that is fast approaching and any help would be greatly appreciated.:(

View 1 Replies View Related

Can't Send This E-mail Message Error

Oct 11, 2006

I've got one of my users which has just started getting the "Can't send this e-mail message" error. Found reference to it being trying to send an email without editing (MS article 884998. My editmessage is set to yes so I know it is not this exact problem but just wondering if anyone else had has this type of issue before and could they get around it?

I tried searching but with such common words it wouldn't return any results.

View 3 Replies View Related

Access 2007 / Send Report To A New File?

Nov 23, 2011

In Access 2007 there a way to send a report to a file you create from the information in the form?

Right now my code for the command button is:

Dim strMyPath As String
Dim strMyName As String
strMyPath =" EBEBMainDigital Sender "
strMyName = "Permit " & Me.[Permit Number].Value
DoCmd.OpenReport "File Current Permit", acViewPreview, , "[ID] = " & Me.[ID]
DoCmd.OutputTo acOutputReport, "File Current Permit", acFormatPDF, strMyPath + strMyName, False
DoCmd.Close acReport, "File Current Permit"

And that works perfect for sending the current report to the Digital Sender Folder... but I'd like to be able to send it to a certain county folder within the digital sender folder, based on what is listed for the county on the form. same for municipalities. and then, have it create a folder based on the name inside the form..... how to lead it through the path of the folder through the given information on the form, or how to make it create a folder.

View 9 Replies View Related

Adding Report Content Into Email Body

Jul 30, 2014

I am trying to work my way into putting the content of my report into the body of an e-mail. I have used the following code to do so but I keep on getting the error: "An Expression You Entered Is the Wrong Data Type for one of the Arguments"

Code:
Private Sub Command278_Click()
On Error GoTo ER
Dim db As Database
Dim rstOpenPurchaseOrders As Recordset
Dim strSQL As String

[Code] .....

View 14 Replies View Related

Modules & VBA :: How To Display All Records From Report On Email Body

Nov 16, 2014

With this very simple command, I have the ability to send emails to several clients, reporting many things, quotations etc.

Private Sub Command84_Click()
DoCmd.SendObject , , , , , , "SOMETHING", [SalesGroupingField] & "" & [1], True, ""
End Sub

Now, i want, on the body of the emai, to display many records, it is from Nothwind, how can i display on the body of the email all records from this report?

View 10 Replies View Related

Modules & VBA :: Adding Report In Outlook Text Body

Aug 5, 2014

I have copied a VBA from the net and it is working fine and producing my report on outlook body text but one problem me facing is that it is pasting only first page if the second page is there it is not coming in outlook text body this what i want rest every thing is correct the code is:

Private Sub Command88_Click()
Const ForReading = 1, ForWriting = 2, ForAppending = 3
Dim fs, f
Dim RTFBody, strTo
Dim MyApp As New Outlook.Application
Dim MyItem As Outlook.MailItem

[Code] .....

View 5 Replies View Related

Mail Once Again - Opening 'new' Mail-window And Export Mail Adress

Jun 23, 2006

Hi, this is probably a very easy question for you Access-gods out there.

Ive made a database (MS Access 2000) with all my clients. I collect a lot of contact info, including e-mail.

I want to make a function which opens a new mail window (Outlook 2003) and automatically puts in the e-mail from my form (In the send-to field of outlook).

Is this possible? And how?

(BTW: Im a newbie with VBA)

View 2 Replies View Related

Modules & VBA :: Vanishing Commas When Exporting Report Into HTML Email Body

Jun 17, 2013

I'm running the following code to generate an email from a report.

Quote:

Function ExportHTML3()
Dim strline, strHTML
Dim OL As Outlook.Application

[Code].....

But I don't really know much VBA and I found that code on the internet, so I can't figure out how it's doing that and if I can stop it. Or is there another way to get the text from the HTML file into the Email body, which brings the bold formatting with it, like the following.

Incident Reference: AA99999

View 4 Replies View Related

Send E-mail To Supplier Using Supplier Field

Feb 29, 2008

hi,

at present i have an order form. this form has a id number and supplier field . at the moment a macro runs a report which produces the order. the macro does ask me for the order number. the order number is the id number, what i would like to do is get a macro that looks at the id field and supplier field, fetch the e-mail address from the supplier table and send the order to the e-mail address

thanks
steve

View 1 Replies View Related

Reports :: Possible To Send Report As XLS And Keep Format Exactly As Report Looks

Jul 11, 2013

I am wondering if it is possible to send a report as xls file and keep the format exactly as the report looks.When I try to send it now, it automatically changes back to the column names from the table, which I in the report have changed and want to keep in my excel output!

View 3 Replies View Related

Bold Within Email Body Generated Within Access

Nov 21, 2006

Hey, I was wondering how I would tell Access to set bold on my email message. I use this code to generate the email:


Private Sub Email_Click()

strToWhom = [EMAIL]

strMsgBody = "This is my email body, I would like this word bold"

DoCmd.SendObject , , , strToWhom, , , "Subject", strMsgBody, True

End Sub

Thanks for any help provided.

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved