Tried it but doesn't seem to be working. It has runtime error 1004 where it says application-defined or object-defined error. My formula basically goes like this.
ActiveCell.FormulaR1C1 = _
"=IF(RC[-1]=""ABCD"",""ABCD"",IF......," & _
"IF(AND(RC[-43]=""123456"",IF.....," & _
"IF(AND(RC[-43]=""123456"",IF.....," & _
"IF(AND(RC[-43]=""123456"",IF.....," & _