Tag: google data api

如何获取Google文档的说明?

目标 假设我在Google文档/云端硬盘中有一个文档集/文件夹,我想以编程方式检索与每个文档关联的说明: (您可以通过选择列表中的文件,然后点击“眼睛”图标来获得此信息) 工作守则 我正在将.NET库用于Google Data API,并且基本的登录和检索工作没有问题: GDataCredentials credentials = BuildSomethingUp(); RequestSettings settings = new RequestSettings(“code.google.com/p/exult/”, credentials); Request request = new Request(settings); Feed feed = request.GetFolderContent(resourceId); List documents = feed.Entries.ToList(); foreach (Document document in documents .Where(item => item.Type != Document.DocumentType.Folder)) { string summary = document.Summary; //y no can haz? } 但是, .Summary属性始终返回null。 问题 我正在假设.Summary是基于一些不推荐的代码部分等的正确位置。这是一个虚假的假设吗? 我怎样才能检索与文档相关的描述? […]

更新Google Spreadsheets中的单元格会返回错误“缺少资源版本ID”/“远程服务器返回错误:(400)错误请求。”

我想更新Google Spreadsheets中的单元格值但不幸的是收到错误: Google.GData.Client.GDataRequestException was unhandled HResult=-2146233088 Message=Execution of request failed: https://spreadsheets.google.com/feeds/cells/1nW8nxoS2l9pbj6dctreEfKHNXmsfbbsCAvOd7TIj4Bo/od6/private/full/R1C1 Source=Google.GData.Client ResponseString=Missing resource version ID StackTrace: at Google.GData.Client.GDataRequest.Execute() … at System.Threading.ThreadHelper.ThreadStart() InnerException: System.Net.WebException HResult=-2146233079 Message=The remote server returned an error: (400) Bad Request. Source=System StackTrace: at System.Net.HttpWebRequest.GetResponse() at Google.GData.Client.GDataRequest.Execute() 我的代码非常简单,基于从https://developers.google.com/google-apps/spreadsheets/?csw=1#changing_contents_of_a_cell下载的示例: SpreadsheetsService service = new SpreadsheetsService(“MySpreadsheetIntegration-v1”); // TODO: Authorize the service object for a specific […]

如何使用Google.Apis.YouTube.v3和C#将video上传到youtube?

我用C#创建了console应用程序。 这将把Video从本地驱动器upload到youtube 。 我使用此链接在google api中创建了新应用。 我还使用nuget安装了所有必需的packages 。 当我运行我的应用程序时,我收到错误“ 访问被拒绝 ”我无法找到问题。 我在Task Run()方法中遇到错误。 using System; using System.IO; using System.Reflection; using System.Threading; using System.Threading.Tasks; using Google.Apis.Auth.OAuth2; using Google.Apis.Services; using Google.Apis.Upload; using Google.Apis.Util.Store; using Google.Apis.YouTube.v3; using Google.Apis.YouTube.v3.Data; namespace Google.Apis.YouTube.Samples { /// /// YouTube Data API v3 sample: create a playlist. /// Relies on the Google APIs Client Library […]

C#类如何处理JSON中的美元符号?

我从Google的数据API获取JSON提要,许多属性名称以$字符(美元符号)开头。 我的问题是我不能创建一个带有以美元符号开头的变量名的C#类,语言不允许这样做。 我正在使用Newtonsoft的JSON.NET将JSON转换为C#对象。 我怎样才能解决这个问题?

阅读Gmail收件箱

我想使用Google.GData.Client.dll阅读我的Gmail收件箱。 我该如何做到这一点? 我想要一个示例程序。