Hi All

I new to python and google calenders but I hope someone can help me, im 
banging my head against the wall

I can create an event easily on my calender with the below python code.

    def _InsertEvent(self, title, content, where, startdate, enddate):
        event = gdata.calendar.data.CalendarEventEntry()
        event.title = atom.data.Title(text=title)
        event.content = atom.data.Content(text=content)
        event.where.append(gdata.data.Where(value=where))
        event.when.append(gdata.data.When(start=startdate, end=enddate))

        new_event = self.cal_client.InsertEvent(event, 
'https://www.google.co.za/calendar/feeds/default/private/full')
        print '\tNew single event inserted: %s' % (new_event.id.text,)
        print '\tEvent edit URL: %s' % (new_event.GetEditLink().href,)
        print '\tEvent HTML URL: %s' % (new_event.GetHtmlLink().href,)
        print new_event

        return new_event

Then i try to store the variable new_event  and later try to delete the 
event by passing the stored new_event etag variable to the delete command 
like so .

      
 
self.cal_client.Delete('https://www.google.com/calendar/feeds/default/private/full/\"E0kCTgdCfSp7JGA6WhJW\";')

but I keep getting the below error


Traceback (most recent call last):
  File "caldelete.py", line 72, in <module>
    main()
  File "caldelete.py", line 69, in main
    sample._Run(funct, delete)
  File "caldelete.py", line 34, in _Run
    
self.cal_client.Delete('https://www.google.com/calendar/feeds/default/private/full/\"E0kCTgdCfSp7JGA6WhJW\";')
  File "/usr/lib/python2.5/site-packages/gdata/client.py", line 748, in 
delete
    **kwargs)
  File "/usr/lib/python2.5/site-packages/gdata/client.py", line 298, in 
request
    **kwargs)
  File "/usr/lib/python2.5/site-packages/gdata/client.py", line 319, in 
request
    RequestError)
gdata.client.RequestError: Server responded with: 404, No events found


I know that event exists because I create it first. Am i not getting the 
right idea.

Any help would be so gratefully appreciated



-- 
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://code.google.com/apis/calendar/community/forum.html

Reply via email to