Need Help with VBA Code

AccessFriend

New member
Local time
Today, 04:06
Joined
Aug 22, 2014
Messages
1
[FONT=&quot]Hello, I am using the following code to create an email out of access 2007 but I have the following issues, can someone please help![/FONT]



  • [FONT=&quot]How do I insert paragraph returns into the text[/FONT]
  • [FONT=&quot]If I decide not to send the email I get an error message[/FONT]
  • [FONT=&quot]I cannot do anything in my database until I hit escape
    [/FONT]
[FONT=&quot]Private Sub EMAIL_Rpt_Click()[/FONT]

[FONT=&quot]With CodeContextObject[/FONT]
[FONT=&quot] DoCmd.Echo False, ""[/FONT]
[FONT=&quot] DoCmd.OpenReport "Final_rpt", acViewPreview, "", "[Bid]=[Forms]![Clients_mmf]![Bid]", acNormal[/FONT]
[FONT=&quot] DoCmd.SendObject acReport, "Final_rpt", "PDFFormat(*.pdf)", "", "", "", "ABC Budgeting for 2015 - " & .Property, "As budgeting season quickly approaches, I thought it would be helpful to share with you the attached 2015 recommendations to aid in your planning and budgeting for the coming year. These recommendations are based on the unique attributes of your property, as well as best practices. As an ABC customer, you understand how our products can help you increase revenue. As we continue to improve and further integrate our product offerings, I am confident that the attached recommendations will help you achieve your 2015 goals. I will be in touch in the next few days to set-up a convenient time to review the attached recommendations together. In the meantime, please feel free to contact me with any questions. I look forward to hearing from you soon! Thanks,", True, ""[/FONT]
[FONT=&quot] DoCmd.Close acReport, "Final_rpt"[/FONT]
[FONT=&quot] End With[/FONT]

[FONT=&quot]End Sub[/FONT]
 

Users who are viewing this thread

Back
Top Bottom