[英]How to apply colors to outlook calendar events using Microsoft graph api?
[英]How to expand Microsoft Graph extended properties in calendar events in a calendar view
使用 Microsoft Graph SDK,我意识到当我从日历事件集合中获取事件时,扩展属性在响应中:
graphClient.Me.Calendar.Events
.Request()
.Expand("SingleValueExtendedProperties($filter=id eq 'String {00020329-0000-0000-C000-000000000046} Name MyExtendedProperty')")
.Select("SingleValueExtendedProperties")
.GetAsync()
但是当我从日历视图集合中获取它们时,扩展属性被省略:
graphClient.Me.Calendar.CalendarView
.Request(new[]
{
new QueryOption("StartDateTime", DateTime.UtcNow.AddMonths(-3).ToString("yyyy-MM-dd")),
new QueryOption("EndDateTime", DateTime.UtcNow.AddMonths(3).ToString("yyyy-MM-dd"))
})
.Expand("SingleValueExtendedProperties($filter=id eq 'String {00020329-0000-0000-C000-000000000046} Name MyExtendedProperty')")
.Select("SingleValueExtendedProperties")
.GetAsync()
有谁知道这是设计限制还是有办法在日历视图中扩展扩展属性?
我尝试使用 Graph API 来扩展日历视图中的扩展属性,它对我有用。
尝试看看您是否可以在此处利用 Rest API。 希望这可以帮助。 谢谢!
@Shweta 是对的,日历视图甚至可以从 SDK 扩展。
我的错误是假设me/calendarView
和me/events
应该返回相同的事件集。
结果me/calendarView
实际上返回重复系列中的单个事件,而不是像me/events
那样的系列主。
这让我误以为我的扩展属性没有包含在内,但实际上由于在日历视图中包含了个别事件,它被推到了后面的页面。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.