且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

使用Google脚本移动日历事件

更新时间:2023-12-05 20:57:46

以下修改如何?

Calendar.Events.move(pubCalId, eventToMove.getId(), privCalId);

收件人:

Calendar.Events.move(pubCalId, eventToMove.getId().replace("@google.com", ""), privCalId);

注意:

  • 检索到的 eventToMove.getId()的ID是 ##### @ google.com .但是用于 Calendar.Events.move()的ID是 ##### .因此需要从 ###### @ google.com 中删除 @ google.com .
    • 在您的脚本中,因为找不到 ##### @ google.com ,所以会发生错误.
    • Note :

      • The id retrieved eventToMove.getId() is #####@google.com. But the id which is used for Calendar.Events.move() is #####. So @google.com is required to be removed from #####@google.com.
        • In your script, because #####@google.com cannot be found, the error occurs.
        • 如果我误解了你的问题,对不起.

          If I misunderstand your question, I'm sorry.