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

SendObject to Lotus Notes failing

I'm using SendObject to generate an email to a list that I have built
up in a string variable from email addresses held in a text field
within a table. The string of email addresses looks OK. I know this
because I've msgboxed it. However while it works OK for the first two
email addresses when I try three or more although it seems to work OK
within Access, the list is corrupt in the generated LN email.

My experience with Access VB is only rudimentary but I think the
following code is OK:

Private Sub SendMail_Click()
On Error GoTo ErrorSendMail_Click
Dim wsp As Workspace
Dim rSetMail As Recordset
Dim qdf As QueryDef
Dim MailList As String
Set wsp = DBEngine.Workspaces(0) ' Allocate workspace for
database
Set qdf = CurrentDb.QueryDefs("qryContactEmail")
For Each prm In qdf.Parameters 'ensure parameters are
evaluated correctly so query name is recognised
prm.Value = Eval(prm.Name)
Next prm

Set rSetMail = qdf.OpenRecordset(dbOpenDynaset)
If rSetMail.RecordCount = 0 Then GoTo NobodytoEmail
MailList = ""
rSetMail.MoveFirst
Do While Not rSetMail.EOF
MailList = MailList & rSetMail![ContactName] & ";"
MsgBox MailList
rSetMail.MoveNext ' move to next record
Loop

DoCmd.SendObject , , acFormatRTF, MailList
Exit Sub

NobodytoEmail:
MsgBox "No contacts have been selected"

ExitSendMail_Click:
Exit Sub

ErrorSendMail_Click:
MsgBox "Error " & Err.Number & ":" & Err.Description
Resume ExitSendMail_Click
End Sub

Anyway I reckon this is a failure within Lotus Notes. Does anyone know
of such a problem or have I just done something wrong in my code?

Thanks,

Roy
Nov 22 '07 #1
0 1288

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...
1
by: Peter Wright | last post by:
Using MSAccess XP how can I use the DoCmd.SendObject to send email using Lotus Notes - we can pop-up a Notes email form completed with header and body data, but need to despatch the email using...
0
by: TR | last post by:
Hi, Just noticed something unusual. If I use Docmd.SendObject in Access 97, access will open up Lotus Notes to send the email. here is the code: DoCmd.SendObject , , , "SomeBody@Somewhere.com",...
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...
2
by: Andy_Khosravi | last post by:
I posted this question about two days ago, but for some reason it never actually got put up. I couldn't' find it with searches, so I am re-posting it now. I apologize if this is a double post. ...
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. ...
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...
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: 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: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.