Sub Demo()
VA = Range("'Refer Sheet'!A1").CurrentRegion.Value
With Range("'Main Data'!A1").CurrentRegion
For L& = 2 To UBound(VA)
VR = Application.Match(VA(L, 1), .Columns(1), 0)
If IsNumeric(VR) Then
VC = Application.Match(VA(L, 2), .Rows(1), 0)
If IsNumeric(VC) Then .Cells(VR, VC).Value = VA(L, 3)
End If
Next
End With
End Sub
Sub DemoNoControl()
VA = Range("'Refer Sheet'!A1").CurrentRegion.Value
With Range("'Main Data'!A1").CurrentRegion
For L& = 2 To UBound(VA)
.Cells(Application.Match(VA(L, 1), .Columns(1), 0), Application.Match(VA(L, 2), .Rows(1), 0)).Value = VA(L, 3)
Next
End With
End Sub