View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default refer to whole column

=sumif(x:x,"xxx",indirect("C"&z999,false))

Where x:x contains the value you want to compare.
And z999 contains the column number


Ken wrote:

Hi!

How do I refer to a whole column by a number of a cell? For example, if a
number of a certain cell is 1, then the column will be A:A. If a number of a
cell is 3, the column will be C:C.

I will be using the result as the [Sum_Range] in a SUMIF function.

Thank you very much!


--

Dave Peterson