Article ID: 161174
Article Last Modified on 1/19/2007
159322 ACC97: Paradox, Lotus, & MS Exchange/Outlook ISAMs in ValuPack
161173 ACC97: MS Exchange ISAM Driver Requires Manual Registration
Folder Message Class
----------------------------
Calendar IPM.Appointment
Contacts IPM.Contact
Inbox IPM.Note
Journal IPM.Activity
Notes IPM.StickyNote
Tasks IPM.Task
Parameter Value
--------------------------------------------------------------------
MAPILEVEL The path to the parent of the folder you want to link.
DATABASE The path and file name of the current database.
PROFILE A valid Microsoft Outlook or Microsoft Exchange
profile.
Function AttachMail()
Dim db As Database
Dim td As TableDef
On Error GoTo Errorhandler
Set db = CurrentDb()
Set td = db.CreateTableDef("tblInbox")
' Substitute your own MAPILEVEL, DATABASE and PROFILE arguments.
td.Connect = "Exchange 4.0;MAPILEVEL=Mailbox - Nancy Davolio|;"
td.Connect = td.Connect & "DATABASE=C:\Program Files\Microsoft "
td.Connect = td.Connect & "Office\Office\Samples\Northwind.mdb;"
td.Connect = td.Connect & "PROFILE=Microsoft Outlook"
' Substitute the name of the folder you want to attach.
td.SourceTableName = "Inbox"
db.TableDefs.Append td
Application.RefreshDatabaseWindow
MsgBox "Table Appended!"
Exit Function
Errorhandler:
Msgbox "Error " & Err & " " & Error
Exit Function
End Function
?AttachMail()
Additional query words: mail mapi mailbox
Keywords: kbhowto kbprogramming kbusage KB161174