Hi,
I would like to perform batch processing, however I want to create and
update events at the same time (during the same batch request).
The issue I'm facing, is not being able to specify which event has to be
updated.
For each event I store an eventID.
Where can I specify an eventID in here?
When using this, an event is updated, but not the one I intended.
Dim toUpdate As EventEntry
toUpdate = DirectCast(feed.Entries(0), EventEntry)
toUpdate.Title.Text = "testA"
toUpdate.BatchData = New GDataBatchEntryData("s4fgk8jmt9sbb5aqpjdm0ltcno",
GDataBatchOperationType.update)
The code is part of this batch request.
Example code:
Dim myService As CalendarService = New
CalendarService("exampleCo-exampleApp-1")
myService.setUserCredentials("****", "****")
Dim query As New EventQuery("
https://www.google.com/calendar/feeds/default/private/full")
Dim feed As EventFeed = myService.Query(query)
Dim batchFeed As New AtomFeed(feed)
Dim toCreate As New EventEntry
toCreate.Title.Text = "testB"
Dim Date As Date = "20/06/2011"
Dim Start As Date = "08:00"
Dim End As Date = "08:15"
toCreate.Times.Add(New [When](Date.ToShortDateString & " " &
Start.ToShortTimeString, Date.ToShortDateString & " " &
End.ToShortTimeString))
toCreate.BatchData = New GDataBatchEntryData("(A)1158",
GDataBatchOperationType.insert)
Dim toUpdate As EventEntry
toUpdate = DirectCast(feed.Entries(0), EventEntry)
toUpdate.Title.Text = "testA"
toUpdate.BatchData = New
GDataBatchEntryData("s4fgk8jmt9sbb5aqpjdm0ltcno",
GDataBatchOperationType.update)
batchFeed.Entries.Add(toCreate)
batchFeed.Entries.Add(toUpdate)
Any help would be greatly appreciated!
Regards,
Dave
--
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