我看到这个命名空间:
System.Runtime.InteropServices.WindowsRuntime
这是提供.NET和WindowsRuntime之间互操作性的工具。
例如,在创建Metro应用程序时,您可以调用WindowsRuntime中的方法,因为Metro使用WindowsRuntime,如下所示:
Windows.System.UserProfile.UserInformation
然而,当您创建普通的.NET控制台应用程序或WPF应用程序时,您不能再直接访问WindowsRuntime命名空间,例如Windows.System。
我想知道是否可能通过在上述命名空间中使用互操作来调用WindowsRuntime方法。
提前致以万分感谢!