Monday, November 11, 2013

Check your Google Calendar with Tasker


I recently decided to play with Tasker for Android, and I've been having a blast with it! Here's one snippet some people may find helpful. It checks my Google Calendar and saves some info about today's schedule to a global variable.

To try it out, first you have to retrieve your Google Calendar private XML URL. It is found in your Google Calendar settings menu. Download this JavaScript file, and change the "username" variable to your Google username. Change the "key" variable to the "private-XXXX" portion of your private XML URL.

Save the updated JavaScript to your device, and create a new task like below.

The JavaScript action is under "Script", and Say is under "Misc". For the JavaScript "Libraries" attribute, click the search icon and select jQuery.

 

I use this as part of my morning profile. It's very flexible if you don't mind playing around with JavaScript. Let me know what you think!

Here's another link to the JavaScript file.



8 comments:

  1. This comment has been removed by the author.

    ReplyDelete
  2. Does it still work? Looks cool but I cant get it to work

    ReplyDelete
  3. This comment has been removed by the author.

    ReplyDelete
  4. Partially working here. Will play around with it for a couple days to see.

    It fetches my calendar and then says "you have three (or how many) appointments today" and then lists the time of the first appointment. If I get a notification during speaking it stops.

    ReplyDelete
  5. Found the problem for me. It wasn't getting the events correct, for example it read events from tomorrow, not from today. Found out the issue is the startMin and startMax. For both, there's a part that reads "-05:00". This is a time zone offset. It's how many hours to offset from UTC time. Use an online tool to find out how much your timezone is off from UTC and then correct it to that. For me, I live in a time zone that is -7 hours from UTC so I changed it to read "-07:00"

    ReplyDelete
  6. Any plans to get this script running again?

    ReplyDelete
  7. Any way this script can be updated with options for iCal now that xml feeds have been disabled by google?

    ReplyDelete
  8. Any way this script can be updated with options for iCal now that xml feeds have been disabled by google?

    ReplyDelete