I wanted to try out the google API and couldn't get the code to work in
C# so I tried VB.NET and I'm getting the same issue.  Below is the code
I'm using but I get an error message on the calservice.query.  Message
is "An unhandled exception of type 'System.NullReferenceException'
occurred in system.xml.dll  Additional information: Object reference
not set to an instance of an object.".  In looking at the sample code I
think I have everything right but I'm stumped.  I'm using VS 2002 and
.NET 1.1.

Thanks,
Nathan


Dim calservice As New CalendarService("nathantest")
Dim eventqry As New EventQuery()
Dim eventfd As EventFeed
Dim eventitm As EventEntry

    calservice.setUserCredentials("[EMAIL PROTECTED]", "***")

    eventqry.Uri = New
Uri("http://www.google.com/calendar/feeds/[EMAIL PROTECTED]/private/full")
    eventqry.StartDate = New Date(2006, 8, 16)
    eventqry.EndDate = New Date(2006, 8, 19)
    eventqry.FeedFormat = AlternativeFormat.Unknown
    eventqry.NumberToRetrieve = 10
    eventfd = calservice.Query(eventqry)
    For Each eventitm In eventfd.Entries
      Debug.WriteLine(eventitm.Id.AbsoluteUri & " / " &
eventitm.Title.Text)
    Next

    eventqry = Nothing
    calservice = Nothing


--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to