的Windows Metro风格应用程序发生错误与谷歌数据API库(Windows Metro St

2019-06-25 08:54发布

操作系统:Windows 8消费者预览版
IDE:Visual Studio的测试版11

我创建了一个空白的应用程序(Windows Metro风格)。
并加入谷歌文档API的示例代码。 (它是下面)
它发生编译错误。( 在找不到模块System.dll中类型System.ComponentModel.ExpandableObjectConverter)

但是,当我创建一个控制台应用程序(Windows)中,不发生编译错误和谷歌文档API的工作好。

有任何想法吗?

using System;
using Google.GData.Client;
using Google.GData.Documents;

namespace MyDocumentsListIntegration
{
  class Program
  {
    static void Main(string[] args)
    {
      DocumentsService service = new DocumentsService("MyDocumentsListIntegration-v1");

      // TODO: Authorize the service object for a specific user (see Authorizing requests)

      // Instantiate a DocumentsListQuery object to retrieve documents.
      DocumentsListQuery query = new DocumentsListQuery();

      // Make a request to the API and get all documents.
      DocumentsFeed feed = service.Query(query);

      // Iterate through all of the documents returned
      foreach (DocumentEntry entry in feed.Entries)
      {
        // Print the title of this document to the screen
        Console.WriteLine(entry.Title.Text);
      }
    }
  }
}

Answer 1:

看来, ExpandableObjectConverter类存在于标准.NET框架,但如果你看看在地铁API文档System.ComponentModel命名空间中,没有列出类等不可用。

我建议使用Metro风格应用.NET页面发现编写Metro风格的应用程序时,什么是可用的。



文章来源: Windows Metro Style app occur error with Google Data API Library