I'm trying to use Index Match formula instead of Vlookup due large amount of datas .
Ive heard that its faster than using Vlookup formula .
However , I encounter an error along this line .
Range("S2").FormulaR1C1 = _
"= INDEX([PatientMerge.xls]2015!C10,Match(C[-16],[PatientMerge.xls]2015!,C10,0))"
I dont know what went wrong with my formula
Please help
Private Sub Unsuccessful()
'Update Column S and T
'S = Active Ext ID , T = Inactive Ext ID
Dim MaxRowNum As Long
With Application
.ScreenUpdating = False
.Calculation = xlManual
End With
Sheets("Simpat").Select
'Find the max number of row
MaxRowNum = 1
Do While Cells(MaxRowNum, 2) <> "" Or Cells(MaxRowNum + 1, 2) <> ""
MaxRowNum = MaxRowNum + 1
Loop
Range("S2").FormulaR1C1 = _
"= INDEX([PatientMerge.xls]2015!C10,Match(C[-16],[PatientMerge.xls]2015!,C10,0))"
With Application
.ScreenUpdating = True
.Calculation = xlCalculationAutomatic
End With
End Sub
Bookmarks