?
Solved

Email Current Record Access 2007 VB Issue

Posted on 2013-01-11
3
Medium Priority
?
431 Views
Last Modified: 2013-01-11
Hi,

I would like to know if it is possible to e-mail fields from the current record only.

I'm writing a holiday calendar.  Once the user enters the start and end date, I want to e-mail this to their manager to authorise.  I don't want to attach a report, just use the dates the user has just entered.

The below is garbage I've written...sorry I know I'm bad...

Dim strMsgBody As String

strMsgBody = " Please Authorise the holiday dates," & [Table].[StartDate] & "to " & [Table].[EndDate]

DoCmd.SendObject acSendNoObject, , , , , , , strMsgBody


Thanks,

Rich
0
Comment
Question by:squidlings
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 61

Accepted Solution

by:
mbizup earned 2000 total points
ID: 38766777
<< I would like to know if it is possible to e-mail fields from the current record only. >>

Do you mean start and end dates as displayed in the record the user is currently seeing on a form?


strMsgBody = " Please Authorise the holiday date: " & Me.[StartDate] & " to " & Me.[EndDate]

' Youll have to fill in more of this line... email addresses, etc
DoCmd.SendObject acSendNoObject, , , , , , , strMsgBody

Open in new window

0
 

Author Comment

by:squidlings
ID: 38766823
Perfecto!!!  Easy as that... Massive thanks.

Rich
0
 
LVL 61

Expert Comment

by:mbizup
ID: 38766827
You're welcome :)
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Phishing attempts can come in all forms, shapes and sizes. No matter how familiar you think you are with them, always remember to take extra precaution when opening an email with attachments or links.
This article shows how to get a list of available printers for display in a drop-down list, and then to use the selected printer to print an Access report or a Word document filled with Access data, using different syntax as needed for working with …
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question