我不知道为什么会出现此错误...此脚本中的所有其他代码都已注释掉...任何帮助将不胜感激!
错误消息:TypeError:在 object 中找不到函数 createEvent。(第 16 行,文件“代码”)
function createEvent(test)
{
var cal = CalendarApp.getCalendarsByName(test);
var title = 'Script Demo Event';
var start = new Date("April 5, 2013 08:00:00 PDT");
var end = new Date("April 5, 2013 10:00:00 PDT");
var desc = "Created using Google Apps Script";
var loc = "Script Center";
var event = cal.createEvent(title, start, end, {description:desc, location:loc});
};