0

When I try to run this line of code, I receive VBA error 1004.

Range("K38").Select
ActiveCell.FormulaR1C1 = "=IFERROR(LOOKUP(2, 1/(COUNTIF($K$36:$K37, WIP_Table[Resource Name])=0), WIP_Table[Resource Name]), """")"

The formula for the cell works when input into Excel manually.

Community
  • 1
  • 1
user11015000
  • 151
  • 1
  • 15

1 Answers1

3

As per my comment to close this thread:

You are using .FormulaR1C1 instead of .Formula. Sidenote: You are using .Select to get an ActiveCell but there is no need to do so. Have a look at this older post on SO.

JvdV
  • 70,606
  • 8
  • 39
  • 70