Skip to content

Instantly share code, notes, and snippets.

@izazueta
Created September 2, 2015 15:41
Show Gist options
  • Save izazueta/d6d9f5145416fc3d5aaa to your computer and use it in GitHub Desktop.
Save izazueta/d6d9f5145416fc3d5aaa to your computer and use it in GitHub Desktop.
Buscar valor en una matriz y devolver la posición de la celda (VBA)
Function Buscar_Celda(valor, matriz As Range)
Dim celda As Range
For Each celda In matriz
If celda.Value = valor Then
Buscar_Celda = celda.Address
Exit Function
Else
Buscar_Celda = "no existe"
End If
Next celda
End Function
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment