473,396 Members | 2,034 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Email Message within MS Access

I have a database that strips an attachment from an MS Outlook e-mail
and saves it to a designated folder. Is there any way to save the
actual message itself?

Nov 13 '06 #1
1 1271
Yes there is. The trick is figuring out which email to save. The
following routine is looking through the sent folder for a certain
email and then saving it. You will have to take it from there and
modify to fit your requirements - different folder and how to identify
which one.

========================================

Set olApp = CreateObject("Outlook.Application")
Set oLMapi = olApp.GetNamespace("MAPI")
Set olF = oLMapi.GetDefaultFolder(olFolderSentMail)
Set olIt = olF.Items
' Set olItems = oLMapi.GetDefaultFolder(olFolderSentMail).Items
For Each m In olIt

' ' If m.Subject = hldSubject Then ' was used
but not now.

If InStr(1, m.Body, hldTimeStamp) 0 Then
wrkSubject = m.Subject
wrkSubject = Replace(wrkSubject, ":", " ")
wrkSubject = Replace(wrkSubject, "/", " ")
saveasname = newsubdir & wrkSubject & " - TmStmp-" &
curdate & ".msg"
m.SaveAs (saveasname)
ordersaved = 1
GoTo getoutofemail
End If
Next m

getoutofemail:

Ron

Nov 14 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: dmiller23462 | last post by:
So here's my problem.....I need to set up different email distributions based on which option in the following Select form has been chosen....For instance if "Putaway" is chosen it needs to email...
7
by: cj | last post by:
If anyone can help me with this, I would reeeeally appreciate it: I am trying to send an email that contains a 'webpage" within it. I have seen this done a million times, like in the emails I get...
1
by: Devonish | last post by:
I am composing an email with Access VB and then sending it from within Access. Everything works correctly (the email actually goes!) but Outlook ask some irritating questions that the user is...
0
by: Bob | last post by:
Hi Everybody I have an MS Access Database that accesses the MS Outlook Inbox. I want to be able to see the full email address that the communication has come from while within Ms Access. ...
7
by: Daven Thrice | last post by:
I know how to send email out of Access, and that's no problem. What I need to figure out is how to receive email into access. Say that I give access an email address, such as access@daven.com. I...
24
by: Arno R | last post by:
Hi all, I have a client with several shoe-shops. Customers can leave their email-address if they want to be notified when there is a sale. Input is validated with instr() I am checking for @...
3
by: Zman | last post by:
I've recently added form functionality on my website, which runs with the aid of a perl script and sends the results via an email message. I'm currently able to import, or link, data from a...
9
by: bobdydd | last post by:
Hullo Everybody I am trying to send a email from WITHIN Access 2000 with a report attached that is generated WITHIN Access in the normal way, but all the help examples I have seen uses an...
3
by: Gerard | last post by:
Hello I have created a windows service to monitor a database, it starts some checks when a timer elapses. The checks send emails depending on their findings. My issue is that when I created a...
3
by: Siv | last post by:
Hi, A little while ago I wrote a small program that allowed the user to view products from a database. The database holds the details of the products which can be viewed via a form and...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.