Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Insert plain text and not attachment
Message
From
04/12/2001 09:39:33
 
 
To
All
General information
Forum:
Visual Basic
Category:
COM, DCOM and OLE automation
Title:
Insert plain text and not attachment
Miscellaneous
Thread ID:
00589254
Message ID:
00589254
Views:
53
Hi,

Can someone tell me how I can insert a plain text into
outlook body (and not attachment) using OLE automation
through VB? For example following code in Access 2K would
create the message but it attaches the textfile in stead
of plain text on the body.

Thanks for any assistance.

Regards
++++++++++++
Private Sub Email2Client(cFileName, cMsgSub)
    Dim cEmailList As String

    Dim oOutlook As Object
    Dim oEmailmsg As Object
   
    Set oOutlook = GetObject(, "outlook.application")
    Set oEmailmsg = oOutlook.CreateItem(0)
    cEmailList = "abc@everybody.com"
    oEmailmsg.Recipients.Add (cEmailList)
    oEmailmsg.Attachments.Add cFileName, 1
    oEmailmsg.Subject = cMsgSub
    oEmailmsg.Display
End Sub
Next
Reply
Map
View

Click here to load this message in the networking platform