Hey Francisco,

There must be an extra message within the exception. Could you print it?
For example it might be that your second user is not a Google Calendar User
(you need to have logged-in Google Calendar at least once for Google
Accounts)

On Tue, Feb 8, 2011 at 2:00 AM, Francisco Nabais Manoel <
[email protected]> wrote:

> I have 2 google accounts with the same create calendar code, one account
> works well, but the second account i got the error 403 forbidden.
>
> the code is:
>
>
> public
> CalendarEntry CreateCalendar(string LoginOwner, string PasswordOwner,
> string Title, string Summary, string Color, string language)
>
> {
>
> try
>
> {
>
> CalendarService myService = new CalendarService("Calendar");
>
> myService.setUserCredentials(LoginOwner +
> "@" + domain, PasswordOwner);
>
> CalendarEntry calendar = new CalendarEntry();
>
> calendar.Title.Text = Title.Trim();
>
> calendar.Summary.Text = Summary.Trim();
>
> calendar.Color = Color.Trim();
>
> calendar.Language = language;
>
> Uri postUri = new Uri("
> http://www.google.com/calendar/feeds/default/owncalendars/full";);
>
> CalendarEntry createdCalendar = (CalendarEntry)myService.Insert(postUri,
> calendar);
>
> return createdCalendar;
>
> }
>
> catch (Exception ex)
>
> {
>
>
Please do:
 System.out.println(ex.getMessage());


> throw ex;
>
> }
>
> }
>
>
>
>
>
> Anyone could help?
>
> --
> 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
>

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