J
Jon Turner
I am trying to read the attributes thru reflection in a method that is
static to a class. my function
GetList in the base class need to retrieve the attrutes from the derived
class. Is there a way
to accomplish this ?
Many Thanks in Advance.
Example
[TestAttribute("TableName")]
class MyClass: BaseClass
{
}
class BaseClass
{
static BaseClass GetList()
{
// here is where I want to read the attributes of MyClass, but
because
// this is static, I can't use the this.GetType() to retrieve
[Type] so
// I can retrieve the attbutes:
Type myType = this.GetType(); //Won't work
}
}
static to a class. my function
GetList in the base class need to retrieve the attrutes from the derived
class. Is there a way
to accomplish this ?
Many Thanks in Advance.
Example
[TestAttribute("TableName")]
class MyClass: BaseClass
{
}
class BaseClass
{
static BaseClass GetList()
{
// here is where I want to read the attributes of MyClass, but
because
// this is static, I can't use the this.GetType() to retrieve
[Type] so
// I can retrieve the attbutes:
Type myType = this.GetType(); //Won't work
}
}