1
是否有可能獲得屬性獲取或設置屬性屬性沒有StackFrame
?如何獲得屬性獲取或設置屬性屬性
例如
[SomeAttribute]
public int SomeProp
{
get
{
//Get of SomeAttribute is set on this property
}
set
{
//Get of SomeAttribute is set on this property
}
}
您可以隨時使用`this.GetType()。GetProperty(「SomeProp」)。Attributes [「AttrName」]` - 但我想你不想硬編碼屬性名稱! – VinayC 2011-01-14 09:00:01