Hi there,

I was using Google Calendar .Net API to create calendar, however I
received {"The remote server returned an error: (400) Bad Request."}
whenever I tried to create calendar. I hope someone can give me a
hint. Thanks much.

Here is my code:

public static String createCalendar(CalendarService myService, string
title, string description, string location)
{
        CalendarEntry calendar = new CalendarEntry();
        calendar.Title.Text = title;
        calendar.Summary.Text = description;
        calendar.TimeZone = "America/Los_Angeles";
        calendar.Hidden = false;
        calendar.Location  = new Where("", "", location);

        // Insert the calendar
        Uri postUri = new Uri("http://www.google.com/calendar/feeds/default/
owncalendars/full");
        CalendarEntry createdCalendar = new CalendarEntry();
        createdCalendar = (CalendarEntry) myService.Insert(postUri,
calendar);
        return createdCalendar.SelfUri.ToString();

        }

--

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.


Reply via email to