是否有文档或简单的解决方案如何在服务器代理上通过外部运行激活用户邮件文件中的外出服务?
我试过这样,但它不起作用......
Dim s As New NotesSession
Dim db As NotesDatabase
Dim doc As NotesDocument
Dim dt As New NotesDateTime(Now)
Set db = s.Getdatabase("SERVERNAME", "MAILFILE")
Set doc = db.Createdocument()
doc.AppointmentType= "2"
doc.BookFreeTime = ""
doc.CreatedByAgent = "1"
doc.ExcludeFromView = "D"
doc.Form = "Appointment"
doc.From = s.Username
doc.Principal = s.Username
Call doc.Replaceitemvalue("$BusyName","")
Call doc.Replaceitemvalue("$BusyPriority","")
Call doc.Replaceitemvalue("$PublicAccess","1")
doc.ApptUNID = doc.Universalid
Call dt.Adjustday(-5)
set doc.EndDate = dt
set doc.EndDateTime = dt
call dt.Adjustday(10)
set doc.StartDate = dt
set doc.STARTDATETIME = dt
doc.Subject = "Out Of Office"
Call doc.Replaceitemvalue("$UpdatedBy",s.Username)
Call doc.save(True,False)
Set doc = db.Getprofiledocument("OutOfOfficeProfile")
Call dt.Adjustday(-5)
Set doc.FirstDayOut = dt
Call dt.Adjustday(10)
Set doc.FirstDayBack = dt
doc.CurrentStatus = "1"
doc.GeneralSubject = "HE IS NOT AVAILABLE"
Call doc.save(True,false)