View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
vinnie vinnie is offline
external usenet poster
 
Posts: 1
Default dynamic name range in VBA

Hi,

Is this the direct code for assigning a dynamic range to the P column
staring with P2 cell? I keep getting a global name error everytime I call
this NameList range. Thanks for the help.


ActiveSheet.Names.Add Name:="NameList",
RefersTo:="=OFFSET(Sheet2!$P$2,0,0,COUNTA(Sheet2!$ P:$P),1)"

-Vinnie