【发布时间】:2011-03-15 23:23:11
【问题描述】:
我的客户使用的是 Lotus Notes 8.0.2。 我正在尝试使用以下 VBScript 调用 Notes API 来发送电子邮件:
dim objNotesSession, objNotesDatabase, objNotesItem, objNotesRichTextItem
set objNotesSession = CreateObject("Lotus.NotesSession")
Call objNotesSession.Initialize("[password here]")
set objNotesDatabase = objNotesSession.GETDATABASE("[server here]", "[path to NSF here]")
set objNotesDocument = objNotesDatabase.CreateDocument
set objNotesItem = objNotesDocument.ReplaceItemValue("Form", "Memo")
set objNotesItem = objNotesDocument.ReplaceItemValue("Subject", "My Test Subject")
set objNotesRichTextItem = objNotesDocument.CreateRichTextItem("Body")
objNotesRichTextItem.AppendText "This is the body"
objNotesRichTextItem.EmbedObject 1454, "", "[path to attachment here]"
objNotesDocument.Send False, "[to address here]"
[cleanup code here]
在 Call objNotesSession.Initialize 上出现以下错误:"Error in loading DLL: Initialize"
如果我注释掉该行,执行“set objNotesDatabase = objNotesSession.GETDATABASE”行,则会收到错误“加载 DLL 时出错:GETDATABASE”
请有人告诉我为什么会这样,我可以做些什么来解决它?
谢谢, 肖恩。
【问题讨论】: