how to extract PST file to html or RTF file

G

Guest

I wanna fo some development on PST file, eatract PST file to html ro RTF
file, and can get the sender address, could you show me a way ? Thanks.
 
M

Michael Bauer [MVP - Outlook]

Not sure what you really want to accomplish. The pst file contains all your
all Outlook messages (e-mails, contacts, tasks etc.). You cannot create one
HTML file from that, but you have to save each single message as an HTML
file.

This loops through your Inbox and saves every MailItem as an HTML file, it
also prints the sender's address into the debug window:

Dim obj as Object
Dim F as Outlook.MapiFolder
Dim Items as Outlook.Items

Set F=Application.Session.GetDefaultFolder(olFolderInbox)
Set Items=F.Items
For Each obj in Items
If TypeOf obj Is Outlook.MailItem Then
Debug.Print obj.SenderEMailAddress
obj.SaveAs "c:\" & obj.Subject & "-" & Format(obj.ReceivedTime,
"yyyymmdd-hhnnss")
Endif
Next

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
Organize eMails:
<http://www.vboffice.net/product.html?id=2006063&cmd=detail&lang=en&pub=6>

Am Mon, 8 Oct 2007 18:41:00 -0700 schrieb KAKA:
 
G

Guest

Thanks for your reply.
I wan to extract all the emails, contact... in a PST file to html or rtf,
including the attachment (only rtf file can contain atachment).
Not in Outlook.
I am using Outlook.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top