473,387 Members | 1,812 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,387 software developers and data experts.

Mapi with Lotus Notes in VB.NET

Hi,

I am trying to use MAPI with Lotus Notes Client. (I have to use MAPI).
I have a MapiFile Object as folows.

Dim mFile(0) As MapiFile
With mFile(0)
.lpszPathName = "C:\test.txt"
.lpszFileName = "C:\test.txt"
.nPosition = 0
.flFlags = 0
.lpFileType = 0
End With

And mapiMessage.nFileCount = 1
mapimessage.lpFiles = mFile

Public Declare Auto Function MapiSendMail Lib "Mapi32.dll" Alias
"MAPISendMail" _
(ByVal pSession As Integer, _
ByVal pUIParam As Integer, _
ByRef pMsg As MapiMessage, _
ByVal pFlags As Integer, _
ByVal pReserved As Integer) As Integer

MapiSendMail(0, 0, msg, 0, 0)

I tried another way also. I included MapiFile in MapiSendMail function
as follows.

Public Declare Auto Function MapiSendMail Lib "Mapi32.dll" Alias
"MAPISendMail" _
(ByVal pSession As Integer, _
ByVal pUIParam As Integer, _
ByRef pMsg As MapiMessage, _
ByRef pFile As MapiFile, _
ByVal pFlags As Integer, _
ByVal pReserved As Integer) As Integer

And tried
MapiSendMail(0, 0, msg, mfile(0), 0, 0)

Both methods open a new message in Lotus Notes, but the attachments
are missing. Subject and body text are coming fine. I am programming
in VB.NET and I am not able to figure out what I am doing wrong.

Any help would greatly be appreciated.

Thank you
Kani
Nov 20 '05 #1
0 1448

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

Similar topics

5
by: NickBlooruk | last post by:
Hello, I have successfully linked a Lotus Notes server to our SQL Server database using an ODBC connection. This works fine when wanting to select records eg openquery(LOTUSNOTES2, 'select *...
10
by: hrishy | last post by:
Hi I have heard rumors that Lotus notes would be moving to db2 as the datastore..would that mean db2 for windows and Linux have a shot in its arm and become as pervasive as oracle and ms-sql...
5
by: Colin Anderson | last post by:
I discovered, with great excitement, this article http://www.davison.uk.net/vb2notes.asp when researching methods for emailing from Access via Notes. Unfortunatly, when I run this I get a...
0
by: PZ Fosbeck | last post by:
I'm not a Lotus Notes developer but thanks to this group's archives have successfully created a function for sending Lotus Notes emails from Access. The follow code works great except I want to...
1
by: Joe | last post by:
HI Has anyone been able to work with lotus notes automation classes??? Can you post sample code of how to use these classes. I have setup in VB but I am not able to port to C# This is what I...
3
by: =?Utf-8?B?SmFtZXNU?= | last post by:
I can create a message and send it via my btopenworld account but is the method the same when using Lotus Notes. I have no experience of Lotus Notes whatsoever. I have never seen it at all. ...
0
by: kohligagan2 | last post by:
Hi, I am working on a scenario . And scenario is I am trying to send an Email using my Lotus notes Client Id ( Lotus notes :- is used for messaging and sending mails work as a middleware) I...
2
by: MarkStorer | last post by:
Hi All I need to email a report (with contains graphs) via Lotus Notes. I've tried the 'SendObjectSnp' method (which works with some Lotus Notes clients (but not many others)); so I used the code...
4
by: Bob Alston | last post by:
I am trying to access data in a Lotus Notes database, from Access. The Notes database is release R5. I installed NotesSQL 8.x and have it working. However it chokes on one of the tables 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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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...

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.