Example Google App Script
So I hacked this together to add a little communication between my (current) favorite methods of staying on my financial track – Google docs and Google Calendar. This is quick and dirty and reads from a spreadsheet the name of a Payee, the Date that a Payment is Due and the Amount Due. It loads this information into an event on the user’s default calendar. Note that this is something I threw together after walking through the first example and reading the API a bit, and it has no logic whatsoever.
As I spend more time on it over the next few days I’ll add the ability to read multiple items from multiple sheets – my organizational system gives me one sheet for each month of a given year. I’d also like to add support for writing to a different calendar, as well as a to-do list or even my new favorite toy – GQueues.
The functionality I’m really looking for is the ability to populate the information from the spreadsheet to multiple sources, and have my to-do list or GQueues push out to each source when the item is completed, ultimately logging the date (and amount paid) back on the spreadsheet. But I tend to get ahead of myself – that will probably require more checks in both directions that I will ever feel like writing.
Oh, and a disclamer – I’m no programmer, I just dabble. If you want to talk to a coder, talk to my brother.
function GoogleAppScriptExample() { var ss = SpreadsheetApp.getActiveSpreadsheet(); //gets the active spreadsheet var sheet = ss.getSheets()[0]; //gets the active sheet var payee = sheet.getRange("A3").getValue(); //you can figure the rest out yourselves, its not that complicated. var dateDue = sheet.getRange("B3").getValue(); var amountDue = sheet.getRange("C3").getValue(); Browser.msgBox("Payee: " + payee + " Due Date: " + dateDue + " Amount Due: " + amountDue); //turn off for real deployment var cal = CalendarApp.getDefaultCalendar(); cal.createEvent(payee + ": " + amountDue, new Date(dateDue), new Date(dateDue)); }
Have fun – I’ll keep posting stuff as I get it done.

