G
Guest
I'm pretty new (ok, REALLY new) to reflection stuff. It is really coming in
handy right now in a project I'm working on.
I've figured out how to disect a .dll file and get all the modules, then get
all the types. Nice. Lots of types in system.windows.forms.dll!!!!
So, here's what I can't figure out yet. Once I've gotten a type:
for Each T as Type in CurrentModule.GetTypes
I want to test to see if the type is a control or not. Basically I'd like to:
If TypeOf T is Control Then...
But that does not work. My only work around is using an activator and
actually creating an instance of the type and checking that, but this is
SLOOOOOOW.
Is there some way to perform a "TypeOf" on a type without creating an
instance?????
thanks in advance.
handy right now in a project I'm working on.
I've figured out how to disect a .dll file and get all the modules, then get
all the types. Nice. Lots of types in system.windows.forms.dll!!!!
So, here's what I can't figure out yet. Once I've gotten a type:
for Each T as Type in CurrentModule.GetTypes
I want to test to see if the type is a control or not. Basically I'd like to:
If TypeOf T is Control Then...
But that does not work. My only work around is using an activator and
actually creating an instance of the type and checking that, but this is
SLOOOOOOW.
Is there some way to perform a "TypeOf" on a type without creating an
instance?????
thanks in advance.