D
Daniel Billingsley
I know I my coffee must have worn off or something, but how do I test if a
given property of type Type is a particular type. Confused?
For example, let's say I have a System.Reflection.PropertyInfo object and I
want to test its PropertyType property to see if the property (that the
PropertyInfo refers to) is a string type.
I now have
if (testProperty.PropertyType.FullName == "System.String")
but that literal is making my hair stand on end. Is that the way you do it
though?
given property of type Type is a particular type. Confused?
For example, let's say I have a System.Reflection.PropertyInfo object and I
want to test its PropertyType property to see if the property (that the
PropertyInfo refers to) is a string type.
I now have
if (testProperty.PropertyType.FullName == "System.String")
but that literal is making my hair stand on end. Is that the way you do it
though?