Hi Everybody,
I've found similar threads but I couldn't find the solution.
I have a table with some info and a macro adding a new line with more info.
I need a code to search the info contained in the first three cells of the new line in the previous rows and return row number with the matching values.
This is my code at the moment but i get error 2015. I think this is due to the definitions of Rigamatch.
Riga is the row number of the new line.
Dim RigaMatch As Variant
Dim ReserachArea As Range
Set ReserachArea = ActiveSheet.Range(Cells(1, 1), Cells(Riga, 3))
FContratti.Cells(Riga, 1).Name = "Crit1"
FContratti.Cells(Riga, 2).Name = "Crit2"
FContratti.Cells(Riga, 3).Name = "Crit3"
MFormula = "MATCH(Crit1 & Crit2 & Crit3 &, ReserachArea, 0)"
RigaMatch = FContratti.Evaluate(MFormula)
Any suggestion?
Thank you
I've found similar threads but I couldn't find the solution.
I have a table with some info and a macro adding a new line with more info.
I need a code to search the info contained in the first three cells of the new line in the previous rows and return row number with the matching values.
This is my code at the moment but i get error 2015. I think this is due to the definitions of Rigamatch.
Riga is the row number of the new line.
Dim RigaMatch As Variant
Dim ReserachArea As Range
Set ReserachArea = ActiveSheet.Range(Cells(1, 1), Cells(Riga, 3))
FContratti.Cells(Riga, 1).Name = "Crit1"
FContratti.Cells(Riga, 2).Name = "Crit2"
FContratti.Cells(Riga, 3).Name = "Crit3"
MFormula = "MATCH(Crit1 & Crit2 & Crit3 &, ReserachArea, 0)"
RigaMatch = FContratti.Evaluate(MFormula)
Any suggestion?
Thank you