您好我正在尝试使用java.i在莲花笔记中创建会议我能够向收件人发送会议邀请。但是当我发送会议时,主席和收件人可用的选项是相同的。(像接受,拒绝)。但主席和收件人的选择应该是不同的。任何人都可以告诉你如何做到这一点?
public DocumentKey save(final Session session, final Database db, boolean send,
String moveToFolder) throws NotesException, Io Exception {
//setBody(null);
Document doc = null;
RichTextItem rti = null;
try {
doc = db.createDocument();
db.getView(ServiceConstants.MEETINGS);
// Here i am setting all the properties for that document.
// I cant post that code as it has
// over 100 properties, so more than 100 lines of code
rti = doc.createRichTextItem(ServiceConstants.BODY);
rti.appendText(getBody());
if ((attachment != null) && (attachment.length > 0)) {
for (int i = 0; i < attachment.length; i++) {
attachment[i].save(rti);
}
}
doc.save(true, true, true);
if (send) {
doc.send();
}
if (!isBlank(moveToFolder)) {
doc.putInFolder(moveToFolder, true);
}
setKey(new DocumentKey(doc.getNoteID()));
} finally {
Helper.cleanupIfNeeded(rti);
Helper.cleanupIfNeeded(doc);
}
return getKey();
}
答案 0 :(得分:1)
要成功安排会议,您需要遵循calendaring and scheduling schema
简而言之:必须在主席的邮件文件中创建会议,邀请必须是对该主文档的响应(doc.MakeResponse(...))并通过邮件发送。 “ApptUnid” - 项目将它们联系在一起。
阅读链接中的文档,非常好
答案 1 :(得分:0)
如果您使用的是Notes / Domino 9.0或更高版本,则应考虑使用lotus.domino.NotesCalendar接口及其相关接口。这些相对较新的界面允许您使用iCalendar格式创建,读取和更新日历条目。
以下是一些示例代码:
// Get the NotesCalendar object from the database
NotesCalendar notesCalendar = session.getCalendar(database);
if ( notesCalendar == null ) {
throw new Exception("Cannot open calendar.");
}
// Create a meeting in iCalendar format
String ical = iCalendarMeeting();
// Create the meeting on the Notes calendar
NotesCalendarEntry entry = notesCalendar.createEntry(ical);
此代码从Database实例创建NotesCalendar实例。然后它以iCalendar格式获得会议的表示(未显示iCalendarMeeting方法)。最后,它调用NotesCalendar.createEntry()来创建会议。 createEntry方法将会议放在组织者的日历上,并向所有与会者发送邀请。