Range("B11").Select
Dim Rmts As String
Dim Busca As String
Rmts = "C:\Users\Treinamento\Desktop\Trabalho em vba\BC\[Relacionamentos.xlsx]Matriz_Trein_Obrigatórios"
Busca = "'!R8C6:R394C34=Busca!R8C2,ROW('"
Range("B11:B450").FormulaArray = _
"=IFERROR(INDEX('" & Rmts & _
"'!R8C3:R394C34,SMALL(IF('" & Rmts & _
Busca & Rmts & "'!R8C6:R394)-7),ROW(R[-10]C[-1])),1),"""")"
I'm trying to make an index formula work in VBA, but the FormulaArray does not support including the entire formula line. I have already seen that it could not exceed more than 255 characters, so I divided it and reduced it to the maximum, but it still does not accept it.
Could you tell me where I'm wrong, or if you really can not make it work with so many characters?
Thank you very much.