Cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Hardcoding Specific Google Calendar into Sample Calendar/Clock

Evening,

playing around with the Sample Calendar/Clock app.. Just to get a better idea of how it works is there a way to hardcode a calendar to use? The Agenda app happily connects to a google calendar... Would like to just sample from one of those calendars Agenda app can see..??

thx

Best Answer
0 Votes
5 REPLIES 5

If you use a real device for testing, then it will use the calendars available on your phone. You can filter the events to a specific calendar source, that's what the Agenda app does.

Best Answer
0 Votes

Found the issue..

I use only All Day Events in a daily roll number for my work in the film industry

In Appointment.js 

all day event was being filtered out

//Exclude all-day events
let events = data.filter(event => {return !event.isAllDay;});

changed to

//Include all-day events
let events = data.filter(event => {return event.isAllDay;});

Worked...

Best Answer
0 Votes

are there any all day events in the calendar used when running to simulator?

I’m trying to troubleshoot something but the simulator only shows no appointments

Best Answer
0 Votes

I think there should be some all day events in there. You don't need to filter if you want to include them.

Best Answer
0 Votes

Trying to use use the calendarIds in events search to filterout all events with only those included from a specific calendar.. Modified the Filter Events 48 hrs to include the id of the specific calendar I want to pole.. Is this correct?? changed cal id to post...

 

// Filter events to 48hr window
const calendarId = ("A61CA6F4-F77A-4FC4-92ED-19DC18C6AB55");
const startDate = new Date();
const endDate = new Date();
startDate.setHours(0, 0, 0, 0);
endDate.setHours(49, 59, 59, 999);
const eventsQuery = { startDate, endDate, calendarId };
return calendars.searchEvents(eventsQuery);
})

Best Answer
0 Votes