我正在创建一个应用程序,以便在Microsoft Graph REST API V1.0的帮助下在sharepoint中使用office 365Excel。使用下面的代码,我可以在根目录中创建一个子目录。如何将Excel文件添加到我的根目录。
var driveItem = new DriveItem
{
Name = name,
Folder = new Folder
{
},
};
await graphClient.Me.Drive.Root.Children.Request().AddAsync(driveItem);
我按照Pulling Excel.xlsx workbook from Sharepoint site using Microsoft Graph API的提示走了很远,但现在我被卡住了,希望能得到一些帮助。 我想从Power Automate流调用Graph API Excel端点,首先我在Graph Explorer中测试,但不能超过一个点。 有效的方法(并确认文件的"mimeType“是"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"): https://graph.micro
我正在尝试通过MS Graph更新列表中的项目。 我尝试使用https://docs.microsoft.com/en-us/graph/api/listitem-update?view=graph-rest-1.0&tabs=cs,但下面的代码在颜色和数量上加了下划线,我无法说服它工作。 Screenshot with the issue here 我也试着跟随.NET Graph SDK Updating Sharepoint Online List Item Values,但也不能正常工作。 尝试将新的ListItem作为变量也可以在一些旧的情况下看到,但现在它只想要Field
我正在使用Microsoft Graph SDK for C#。链接如下(“”)。我用于从SharePoint站点获取所有项目的查询如下所示。
// Get Graph API Token
GraphServiceClient client = await MicrosoftGraphClient.GetGraphServiceClient();
// Fetch all DriveItems from Sharepoint Site
var results = await client.Sites[sharePointId].Drive.Root.ItemWithPath("Sa
在我使用Graph SDK编写的C#代码中,我正在使用这里提供的一个方法测试“下载大文件”:Download large files from OneDrive using Microsoft Graph SDK 但是,即使我在调用此方法之前显式地从服务请求DriveItem (然后在DriveItem中使用来自AdditionalData的downloadUrl ),我也得到了一个指示JWT令牌已过期的响应。 我假设这个令牌嵌入在预验证的downloadUrl中。此外,我推测这个令牌要么是一次性使用的,要么是相对过期的,这是我在尝试使用该DriveItem之前显式请求该URL的原因。 我如
我找不到任何关于如何使用MS Graph SDK将文件上传到SharePoint库子文件夹的示例。 这些帖子展示了如何使用REST API,而不是C# SDK来做这件事。 upload files in a folder in Sharepoint/OneDrive library using graph api How to perform a resumable Upload to a SharePoint Site (Not Root) Subfolder using MS Graph API
我在微软的图形api上遇到了一个奇怪的问题。我正在尝试检索存储在Sharepoint上的文件。我不知道问题出在哪里,我已经尝试了很多不同的方法:
为站点获取所有驱动器的调用将起作用,并返回所有可用驱动器的列表:
GET https://graph.microsoft.com/v1.0/sites/site.sharepoint.com,<id>,<id>:/teams/myTeam:/drives
通过前一个端点,我可以提取该驱动器的id,然后我想用它来检索驱动器详细信息(以及该驱动器的所有子驱动器):
GET https://graph.microsoft.com/v
当我尝试从API Graph下载一个文件,在SPFx上使用javascript访问驱动器或站点时,这返回undefined。 我的code部件代码: import { Version } from '@microsoft/sp-core-library';
import {
BaseClientSideWebPart,
IPropertyPaneConfiguration,
PropertyPaneTextField
} from '@microsoft/sp-webpart-base';
import * as strings from '
继续我之前的问题,
我们是否可以将@microsoft.graph.conflictBehavior注释直接添加到SDK调用中,而不是在foldertoCreate对象中指定它呢?
var foldertoCreate = new DriveItem {
Name = $"TestFolder",
Folder = new Folder (),
AdditionalData = new Dictionary<string, object> {
{ "@microsoft.graph.conflictBehavior&