【发布时间】:2015-10-20 09:47:32
【问题描述】:
我最近安装了 Azure Active Directory Graph 客户端库 2.0.2 Nuget 包,无法将成员添加到组中,无论是向组中添加组还是向组中添加用户时,我都收到以下错误 AddLink函数被调用:
“[System.InvalidOperationException] = {"上下文当前没有跟踪实体。"}
我的代码:
IGroup group = azureClient.Groups.GetByObjectId("Guid here").ExecuteAsync().Result;
IGroup groupToAdd = azureClient.Groups.GetByObjectId("Guid here").ExecuteAsync().Result;
azureClient.Context.AddLink(group, "Members", groupToAdd);
azureClient.Context.SaveChanges();
在进行 Google 搜索时,我无法找到与 Azure Active Directory Graph 客户端库相关的任何提及此错误的信息,因此我们将不胜感激。
【问题讨论】:
标签: c# .net-4.5 azure-active-directory