IF Formula

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I would like to write and copy an IF formula across a series of columns where the logic test changes based on where a particular column is in the range. For example in the first cell the formula would be =if(x>y,a,c) and in the second cell (second column in the range of cells) the formula would be =if(x>2y,a,c) and so on. Thanks as always for your assistance
 
Hi
do you want to multiply a value with the current column index. If yes
try
=IF(x>COLUMN()*y),a,c)

If this is not what you want you may post your current excat formula
and state how you want to change it for each column
 
Aspen,

If your columns are A (first cell) and B (second cell) you could use :

=IF(x>COLUMN()*y,a,c)

The column function return a number 1 (A) to 256 (IV).

--
Regards,
Auk Ales

* Please reply to this newsgroup only *
* I will not react on unsolicited e-mails *

Aspen said:
I would like to write and copy an IF formula across a series of columns
where the logic test changes based on where a particular column is in the
range. For example in the first cell the formula would be =if(x>y,a,c) and
in the second cell (second column in the range of cells) the formula would
be =if(x>2y,a,c) and so on. Thanks as always for your assistance.
 
If the first cell is A2...

=IF(x>(COLUMN()-COLUMN($A$2)+1)*y,a,c)

Note that the COLUMN($A$2) bit anchors the formula to the first cell it's
entered. The formula will not break when you insert column(s) before the
current column A.

Aspen said:
I would like to write and copy an IF formula across a series of columns
where the logic test changes based on where a particular column is in the
range. For example in the first cell the formula would be =if(x>y,a,c) and
in the second cell (second column in the range of cells) the formula would
be =if(x>2y,a,c) and so on. Thanks as always for your assistance.
 
Back
Top