Excel IF Formulas

Davis10

New Member
Joined
Jun 21, 2011
Messages
27
I have a formula that looks on a different tab in the workbook, and if in the row the formula looks there is a "Y" then it retrieves the persons information and populates the cells in the tab with the formula. Right now the formula looks like this:


=IF(ROW()-6>COUNTIF(Attendees!$J$6:$J$400,"Y"),"",SMALL(((Attendees!$J$6:$J$400="Y")*(ROW(Attendees!$J$6:$J$400))),(ROW())-6+COUNTIF(Attendees!$J$6:$J$400,"<>"&"Y")))

But the column in which "Y" would be has changed from J ,in the formula above, to column M. However when I change the J to an M, I get an error that says #NUM. I have tried everything I can think of, any idea why I get an error?
 

Excel Facts

Links? Where??
If Excel says you have links but you can't find them, go to Formulas, Name Manager. Look for old links to dead workbooks & delete.
Davis,

I think it is something with formatting of cells in column M. Inspect it's formatting and make sure it is the same as it was in column J. There is no way that the formula is not working if you simple change only column you reference to.
Also use Tools > Formula Auditing > Evaluate Formula to see when and where exactly it show an error.
 
Upvote 0
Find one of the cells which contain Y and type =A1="Y" (replace A1 with the cell reference) and see if it returns TRUE. If not, check for leading or trailing spaces.
 
Upvote 0
It was an array formula so I just needed to ctrl-shift-enter instead of just enter. Thanks for all the help!
 
Upvote 0

Forum statistics

Threads
1,216,138
Messages
6,129,099
Members
449,486
Latest member
malcolmlyle

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