0

I want to use VBA to insert a named range into a cell. My named range (WBS) is from a column in a table (Table1) (third image). If I manually type =WBS into cell D13, it spills all of the named range (first image). However, when I try and insert it using VBA, it puts =@WBS (second image) and doesn't spill all of the results. I have attached a number of screenshots below showing what I want versus what I get. How can I make it insert the correct function?

What I want What I want

What I end up with What I end up with

Named Range WBS Named Range WBS

Here is my code;

Range("D13:D300").ClearContents
Range("D13").Formula = "=WBS"

I also tried

Range("D13").FormulaArray = "=WBS"

but got this -> {=WBS}.

enter image description here

eyeScream
  • 71
  • 9

0 Answers0