I'm trying to port a simple application to Windows 8 Metro (WinRT). It seems that some very basic methods are missing. One basic example: Type.GetProperty()
. It is available for Windows Phone 7, Silverlight and .NET client profile. Do I have to install something (eg. a special library) or is this method simply not available in the .NET metro profile?
UPDATE
OK, thank you. Now I use this.GetType().GetTypeInfo().DeclaredProperties
.
using System.Reflection;
is needed to have this GetTypeInfo()
extension method.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…