Increasing Column Number using IF formula when dragging across

VanessaDowning

New Member
Joined
Jul 1, 2013
Messages
9
Hi, I have a formula =IF($K$11=1,$J$11,"") in column AD

When I drag the formula to the right, I want to "1" to increase in value by 1.

So, as the formula is dragged to the right, the formula changes to:
  1. =IF($K$11=2,$J$11,"") in column AE, then
  2. =IF($K$11=3,$J$11,"") in column AF, then
  3. =IF($K$11=4,$J$11,"") in column AG, etc, etc

Is there an easy way to make this work please? I just can't figure it out....

Thank you
 

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".
Hi
May be
In column AD
Excel Formula:
=IF($K$11=COLUMN()-28,$J$11,"")
 
Upvote 0
Hi
May be
In column AD
Excel Formula:
=IF($K$11=COLUMN()-28,$J$11,"")
Hi Mohadin,

Thanks for your reply.

Sorry I think that I didn't explain it well.

The value in column K will be manually entered. I've shown a screenprint below - not sure if that will help please?

1606296830263.png


Thanks again.

Kind Regards,

Vanessa
 
Upvote 0
try this in AD14

=IF($K14=(COLUMN(AD1)-COLUMN($AC$1)),$J14,"")
 
Upvote 0
it works for me

Book1
JKACADAEAF
1
2
3
4
5
6
7
8
9
10
11
12
13
1410110  
Sheet1
Cell Formulas
RangeFormula
AD14:AF14AD14=IF($K14=(COLUMN(AD1)-COLUMN($AC$1)),$J14,"")


Book1
JKACADAEAF
1
2
3
4
5
6
7
8
9
10
11
12
13
14202 20 
Sheet1
Cell Formulas
RangeFormula
AD14:AF14AD14=IF($K14=(COLUMN(AD1)-COLUMN($AC$1)),$J14,"")


Book1
JKACADAEAF
1
2
3
4
5
6
7
8
9
10
11
12
13
14333  33
Sheet1
Cell Formulas
RangeFormula
AD14:AF14AD14=IF($K14=(COLUMN(AD1)-COLUMN($AC$1)),$J14,"")
 
Upvote 0
is this what you're after?

Book1
JKADAEAF
1
2
3
4
5
6
7
8
9
10
11
12
13
1410110  
15202 20 
16303  30
Sheet1
Cell Formulas
RangeFormula
AD14:AF16AD14=IF($K14=(COLUMN(AD1)-COLUMN($AC$1)),$J14,"")
 
Upvote 0
Oh darn - it still isn't working for me....no idea what I'm doing wrong.....??? I've formatted Column J to be currency and Column K to be as a number, but it's still not working..... :confused:
DOH!!!! I've just realised that I'm trying to copy it into cell AD11, not cell AD14....
It works!!!!
Well done, AlanY - you're brilliant!
 
Upvote 0

Forum statistics

Threads
1,214,925
Messages
6,122,301
Members
449,078
Latest member
nonnakkong

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top