I have the following formula,
=IF(valumeasure3!E2="Buy Notional Amount",VLOOKUP(C2,valumeasure3!C:U, COLUMNS(C:U),FALSE),0)
trying to automate this formula in vba, I get a syntax error. Vlookup formulas work fine, but as soon as I do the IF statement i get syntax error. I believe it is to do with the =
Range("R2").Select
ActiveCell = "=IF(valumeasure3!E2="Buy Notional Amount",VLOOKUP(C2,valumeasure3!C:U, COLUMNS(C:U),FALSE),0)" ''buy currency amt
Selection.AutoFill Destination:=Range("R2:R4182")