View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.misc
Toppers Toppers is offline
external usenet poster
 
Posts: 4,339
Default Merged cells and formula data sources

in c1: =A1*B1
in c2: =IF($A2=0,($C1/$B1)*$B2,$A2*$B2)

Copy down

"radellaf" wrote:

I'm working on a sheet where I need a formula in a column that is, say, col A
* col B. Easy without merged cells.

Say that nothing in Col B is merged. But, Col A, for instance, consists of
two cells vertically merged, maybe 3 or 4 in places. So A1 and A2 are a
single cell with one number, and B1 and B2 are separate cells with different
numbers.

I want two results - A (merged) times B1 in C1, A(merged) times B2 in C2.

Excel unfortunately evaluates A2 as a zero.

Is there a way to get it to correctly find the value of entries in col A?

A cells are not always in pairs, so just referring one-row-up in every other
C formula will not work. I'm thinking there might be a function that returns
the highest value of a cell and any cells it is merged with.
like =MERGEDHIGHEST(A2) would discover A1 and A2 are merged, and return the
number in A1 rather than the phantom zero in A2.