Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to send email to Lotus Notes using Visual Basic 6
Message
 
 
À
06/07/2000 03:40:06
Chamil Mendis
John Keels Computer Services Pvt Ltd.
Colombo, Sri Lanka
Information générale
Forum:
Visual Basic
Catégorie:
Contrôles ActiveX
Divers
Thread ID:
00388735
Message ID:
00389107
Vues:
21
I wrote this with Visual FoxPro in mind and I translated it to VB. You may have to tweak it alittle:

Const EMBED_ATTACHMENT 1454
dim oDoc as NotesDocument
dim oDB as Notesdatabase
dim oRTItem as NotesRichTextItem

Set oSession = createobject("notes.
Set oDB = oSession.GetDatabase("","Test.nsf")
Set oDoc = oDB.CreateDocument()
oDoc.Form = "Memo"
oDoc.SendTo = "Somebody@somewhere.com"
oRTItem = oDoc.CreateRichTextItem("Body")
oRTItem.EmbedObject(EMBED_ATTACHMENT,"","C:\Spreadsheet.XLS","DisplayName")
oDoc.Send(0)
Set oRTItem = Nothing
Set oDoc = Nothing
Set oDB = Nothing
Set oSession = Nothing
The "" in the Getdatabase() function is used to determine the server. If you pass in "", the local machine will be used.

>I had a requirement of sending an email using VB 6 to the Lotus Notes
>email package.
>
>I had tryied the following but failed,
>
>1. setting a reference to the "Lotus Domino objects" and "lotus Notes Automation Classes" and using the reference
>2. Using MAPI controls
>3. Using CreateObject("Lotus.NoteSession")
>
>If any body can help me to solve this would be much appriciated.
>
>Hope a quick reply on this.
>
>Thanks.
>
>Chamil B Mendis
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform