C#으로 반복 일정을 추가하고 싶습니다. 나는 웹에서 다음과 같이 작동한다는 것을 발견했다. 항목을 삽입하는 메서드를 실행하면 실패합니다. EventEntry insertedEntry = service.Insert (calendarUri, entry); 성명!되풀이 항목을 추가하는 방법 Google 캘린더
는이 오류를 얻을 : "요청의 실행이 실패 https://www.google.com/calendar/feeds/[email protected]/private/full?gsessionid=6eGsOTuhQ-YUVWp2BV_25g"나는 재발 코드를 제거하면
이 모든 것이 잘 작동! 나는이 코드 조각이 꽤 오래되었다는 것을 알아 차렸다. .NET 라이브러리로 Google 캘린더에 반복 일정을 추가하는 방법은 무엇입니까? 스트레이트 구글에서
EventEntry entry = new EventEntry();
entry.Title.Text = "Hello World !";
// Recurring event:
String recurData =
"RRULE:FREQ=WEEKLY;WKST=SU;UNTIL=20131010;BYDAY=SU\r\n";
Recurrence recurrence = new Recurrence();
recurrence.Value = recurData;
entry.Recurrence = recurrence;
string htmlDescription = "Woww, really ?";
if (htmlDescription != null && htmlDescription.Length > 0)
{
entry.Content.Type = "html";
entry.Content.Content = htmlDescription;
}
Where eventLocation = new Where();
eventLocation.ValueString = "Somewhere";
entry.Locations.Add(eventLocation);
DateTime start = DateTime.Now;
When eventTime = new When();
eventTime.StartTime = start;
DateTime endTime = DateTime.Now.AddHours(2);
eventTime.EndTime = endTime;
entry.Times.Add(eventTime);
eventTime.AllDay = true;
EventEntry insertedEntry = service.Insert(calendarUri, entry);
무엇이 오류입니까? – Mitch
"시도 할 때 오류가 발생합니다." "오류"가 무엇을 의미하는지 말하지 않는 한, 귀하를 제외한 모든 사람에게 절대적으로 의미가 없습니다. 컴파일러 오류입니까? 런타임 오류? 오류가 어디에서 발생합니까? ** 정확한 ** 오류 메시지와 함께 질문을 수정하고 받고있는 오류에 대해 설명하십시오. 알아 내려고 노력하는 코드를 통해 우리가 읽을 것을 기대하면 훨씬 느리게 도움을받을 수 있습니다. –
네가 옳다 니 미안해! 정확한 오류로 편집했는데, 그것은 나에게 여전히 의미가 없습니다. – yhcowboy