private PropertyInfo ObtenerElPropertyDelObjetoSiExiste() { IdConPunto referencia = (IdConPunto)lValue; string id = referencia.instancia(); Objeto instancia = tablaDeSimbolos.Valor(id); string nombreDeLaPropiedad = referencia.Propiedad(); string propertyUnsensitivo = nombreDeLaPropiedad.ToUpper(); PropertyInfo propertyEncontrado = null; foreach (PropertyInfo property in instancia.GetType().GetProperties(BindingFlags.NonPublic | BindingFlags.Public | BindingFlags.Instance)) { string propertyName = property.Name.ToUpper(); if (propertyName == propertyUnsensitivo && property.SetMethod != null) { ParameterInfo[] variables = property.SetMethod.GetParameters(); variables = QuitarleValueDelSetProperty(variables); bool tienenLaMismaCantidadDeArgumentos = (variables.Length == 0 && referencia.Argumentos() == null) || (variables.Length == referencia.Argumentos().Length); if (tienenLaMismaCantidadDeArgumentos) { bool sonValidasLasFirmas = referencia.ValidarLaIntegridadDeLosArgumentosDelMetodo(variables); if (sonValidasLasFirmas) { propertyEncontrado = property; break; } } } } return(propertyEncontrado); }