2015-11-08 53 views

回答

4

我知道在WinRT中检索程序集的唯一方法是通过GetTypeInfo扩展方法。它在命名空间System.Reflection中定义:

using System.Reflection; 

... 

     foreach (var attribute in this.GetType().GetTypeInfo().Assembly.CustomAttributes) 
     { 
      Debug.WriteLine(attribute); 
     } 
相关问题