Solved

Why array formula is not working to list the cells that have either text or values in them?

Posted on 2014-07-18
7
225 Views
Last Modified: 2014-07-18
I am trying to find the 1st, 2nd, 3rd, 4th, 5th, 6th and 7th cells that have either text or data in them from G10:M10.

The array formula I am using is giving me an error:
INDEX($G$10:$M$10;SMALL(IF($G$10:$M$10<>"";COLUMN($G$10:$M$10)-COLUMN($G$10)+1);1))

Please see attached.
Non-Blank-Cells.jpg
Non-blank-cells.xlsx
0
Comment
Question by:cssc1
7 Comments
 
LVL 23

Assisted Solution

by:NBVC
NBVC earned 125 total points
ID: 40205278
Are you confirming with CTRL+SHIFT+ENTER?

If that is not the problem, then:

Should you be using the semi-colon ( ; ) or the comma ( , ) ?

If I use semi-colon, I get error, but not if I use comma.

Try:

=IFERROR(INDEX($G$10:$M$10,SMALL(IF($G$10:$M$10<>"",COLUMN($G$10:$M$10)-COLUMN($G$10)+1),ROWS($C$10:$C10))),"")

confirmed with CTRL+SHIFT+ENTER not  just enter, then copy down to get remaining.
0
 
LVL 27

Expert Comment

by:Glenn Ray
ID: 40205294
You need to use commas instead of semi-colons.

However, if you want to see the nth items listed, enter this array formula in cell C10 and then copy and paste down to C16:
=IFERROR(INDEX($G$10:$M$10,SMALL(IF($G$10:$M$10<>"",COLUMN($G$10:$M$10)-COLUMN($G$10)+1),ROW()-9)),"")

-Glenn
0
 
LVL 27

Expert Comment

by:Glenn Ray
ID: 40205321
Wait a minute...do you want to see the cell addresses containing the non-blank values?  That would be different...
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 22

Assisted Solution

by:Ejgil Hedegaard
Ejgil Hedegaard earned 125 total points
ID: 40205345
The row reference 1 should be in front of Small
=IFERROR(INDEX($G$10:$M$10,1,SMALL(IF($G$10:$M$10<>"",COLUMN($G$10:$M$10)-COLUMN($G$10)+1),B10)),"")
B10 is the search number 1 to 7 for the Small function, see file

Besides that, my delimiter in formulas are semi-colon.
That depends on country.
Non-blank-cells.xlsx
0
 
LVL 27

Assisted Solution

by:Glenn Ray
Glenn Ray earned 250 total points
ID: 40205391
If you wanted the addresses of the cells with values returned, use this array formula instead ([Ctrl]+[Shift]+[Enter]):
=IFERROR(ADDRESS(10,6+SMALL(IF($G$10:$M$10<>"",COLUMN($G$10:$M$10)-COLUMN($G$10)+1),ROW()-9)),"")

Example workbook updated.


-Glenn
EE-Non-blank-cells.xlsx
0
 
LVL 27

Accepted Solution

by:
Glenn Ray earned 250 total points
ID: 40205394
Ejgil wrote:
Besides that, my delimiter in formulas are semi-colon.
 That depends on country.

Good point; I forgot about that.

-Glenn
0
 

Author Closing Comment

by:cssc1
ID: 40205615
Wow, You guys got it!

Thanks!
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Workbook link problems after copying tabs to a new workbook? David Miller (dlmille) Intro Have you either copied sheets to a new workbook, and after having saved and opened that workbook, you find that there are links back to the original sou…
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
This Micro Tutorial will demonstrate how to use longer labels with horizontal bar charts instead of the vertical column chart.
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question