10̓R[hꗗ

LESSON 28@Cxg擾悤

SECTION 1@Ԃw肵Ď擾

Ԃw肵ăCxg擾

function checkSchedule() {
  const myCal = CalendarApp.getDefaultCalendar();
  const startTime = new Date('2026/05/05 00:00:00');
  const endTime = new Date('2026/05/07 23:59:59');
  const quests = myCal.getEvents(startTime, endTime);
  for (const quest of quests) {
    console.log(`\蔭: ${quest.getTitle()}`);
  }
}

SECTION 2@tw肵Ď擾

tw肵ăCxg擾

function findImportantMeeting() {
  const myCal = CalendarApp.getDefaultCalendar();
  const targetDate = new Date('2026/05/05');
  const options = { search: 'c' };
  const meetings = myCal.getEventsForDay(targetDate, options);
  for (const meeting of meetings) {
    console.log(`c̗\: ${meeting.getTitle()}`);
  }
}

LESSON 29@CxgmF悤

SECTION 1@IDgăCxg肷

function getMeetingId() {
  const myCal = CalendarApp.getDefaultCalendar();
  const targetDate = new Date('2026/05/05');
  const options = { search: 'c' };
  const meetings = myCal.getEventsForDay(targetDate, options);
  for (const meeting of meetings) {
    console.log(`c̗\: ${meeting.getTitle()}y${meeting.getId()}z`);
  }
}

CxgIDŗ\擾

function getScheduleByEventId() {
  const myCal = CalendarApp.getDefaultCalendar();
  const savedId = e XXXXXX@google.comiCxgIDj';
  const targetEvent = myCal.getEventById(savedId);
  console.log(`ID擾\薼: ${targetEvent.getTitle()}`);
}

SECTION 2@Cxg̓eǂݏo

Cxg̏ڍׂ\

function readEventDetails() {
  const myCal = CalendarApp.getDefaultCalendar();
  const savedId = e XXXXXX@google.comiCxgIDj';
  const targetEvent = myCal.getEventById(savedId);
  console.log(`\薼: ${targetEvent.getTitle()}`);
  console.log(`ꏊ: ${targetEvent.getLocation()}`);
  console.log(`: ${targetEvent.
    getDescription()}`);
  console.log(`Jn: ${targetEvent.getStartTime()}`);
  console.log(`I: ${targetEvent.getEndTime()}`);
}

SECTION 3@Cxg̓e

CxgIDw肵ēeύX

function updateEventInfo() {
  const myCal = CalendarApp.getDefaultCalendar();
  const savedId = e XXXXXX@google.comiCxgIDj';
  const newStart = new Date('2026/05/05 10:00:00');
  const newEnd = new Date('2026/05/05 15:00:00');
  const targetEvent = myCal.getEventById(savedId);
  targetEvent.setTime(newStart, newEnd);
  targetEvent.setTitle('ydvzVicij');
  targetEvent.setDescription('yύXzc_MȂߎԂBǉňĂƁB');
}

J_[ɃsNjbN̗\͂

function createPicnicEvent() {
  const myCal = CalendarApp.getDefaultCalendar();
  const startTime = new Date('2026/05/10 09:00:00');
  const endTime = new Date('2026/05/10 16:00:00');
  const options = {
    location: 'ӂ̌',
    description: 'R[XPƃlƂ'
  };
  myCal.createEvent('sNjbN', startTime, endTime, options);
}
