I get nothing when I run the following code. There are no apparent errors. Just nothing happens. Hope someone can tell me where I have gone wrong. Thanks.
<html> <head> <script type="text/javascript" src="http://www.google.com/jsapi? key=ABQIAAAA4kl4tf3SjYiNNwVo8> google.load("gdata", "1"); var appt = 'test appointment'; var pat = 'test pat'; var office = 'test location'; var feedUrl = "http://www.google.com/calendar/feeds/default/private/ full"; function logMeIn() { scope = "http://www.google.com/calendar/feeds/"; var token = google.accounts.user.login(scope); } function setupMyService() { var myService = new google.gdata.calendar.CalendarService('exampleCo- exampleApp-1'); logmein(); return myService; } function getMyFeed() { myService = setupMyService(); myService.getEventsFeed(feedUrl, insertIntoMyFeed,handleError); } function insertIntoMyFeed(feedRoot) { var newEntry = new google.gdata.calendar.CalendarEventEntry({ authors: [ { name: "Rick", email: "[email protected]" } ], title: {type: 'text', text: appttype}, content: {type: 'text', text: "pat id: " + pat}, locations: [ { rel: "g.event", label: "Event location", valueString: office } ], times: [ { startTime: google.gdata.DateTime.fromIso8601("2009-11-23T13:00:00.000Z"), endTime: google.gdata.DateTime.fromIso8601("2009-11-23T15:00:00.000Z") } ] } ); feedRoot.feed.insertEntry(newEntry, function() {alert('event inserted');}, handleError); } function handleError(e) { alert("There was an error!"); alert(e.cause ? e.cause.statusText : e.message); } </script> </head> <body onload="getMyFeed()"> <IMG src="images/pixel.gif"> </body> </html> -- You received this message because you are subscribed to the Google Groups "Google Calendar Data API" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-calendar-help-dataapi?hl=en.
