VBA: How to add formula to DataValidation

50 Views Asked by At

I want to add DataValidation to range (more than one Cell) Formula:

=OFFSET(INDIRECT("System_General_Cargo[[#Headers];[Location]]");MATCH(B20;INDIRECT("System_General_Cargo[Location]");0);1;COUNTIF(INDIRECT("System_General_Cargo[Location]");B20);1)
  • First Question: What is the code
  • Second Question: I want to replace B20 (because its range) with @Column2 or [@Column2]. I can't enter it even without VBA.

Error:

We found problem with this formula. Try clicking Insert function on the formula tab.......

VBA code replace B20 with dynamic cell address

0

There are 0 best solutions below