private static CPA GetCPA( PropertyInfo prop ) { object[] attrs = prop.GetCustomAttributes( typeofCPA, false ); if ( attrs.Length > 0 ) return attrs[0] as CPA; else return null; }