berthe
28th March 2006, 17:31
Hi,
Can anyone tell me how I can insert a Appointment or task in the Outlook Calendar? Sending a mail works just fine.
I would like to use the cmf functions.
Thanks in advance!
Berthe
NPRao
28th March 2006, 22:21
Berthe,
Refer to the links -
cmf.createAppointment() (http://www.baanboard.com/programmers_manual_baanerp_help_emessage_connector_cmf_createappointment)
cmf.createTask() (http://www.baanboard.com/programmers_manual_baanerp_help_emessage_connector_cmf_createtask)
berthe
29th March 2006, 09:21
Ok, I know these functions but I can make them work. An example would be very handy.
Berthe
NPRao
20th May 2006, 02:53
Berthe, here is an example program. Thanks to a BaaN friend who helped me to get it working.
function main()
{
#include <bic_cmf>
long ret, task.id, att.id, mess.id
string messagestr(255)
domain ttutc start.date, due.date, rem.time
mess.id = cmf.create()
task.id = cmf.createTask()
att.id = cmf.createAttachment(task.id)
ret = cmf.setAttachmentMIME(att.id, "text/plain")
ret = cmf.setAttachmentFilename(att.id, "/app/common/home/bsp/filename")
e = cmf.setTaskSubject(task.id, "Testing")
e = cmf.setTaskPriority(task.id, ttcmf.prio.high)
start.date = utc.num()
e = cmf.setTaskStartdate(task.id, start.date)
due.date = utc.num() + 1800 |* 30 minutes
e = cmf.setTaskDuedate(task.id, due.date)
rem.time = utc.num() + 900 |* 15 minutes
e = cmf.setTaskReminderTime(task.id, rem.time)
ret = cmf.addObjectToMessage(task.id, mess.id, "CMF.TASK")
ret = cmf.sendToPerson(mess.id, 0, 0, 0, messagestr)
}