find first cell containing text in a range

Rubber Beaked Woodpecker

Board Regular
Joined
Aug 30, 2015
Messages
208
Office Version
  1. 2021
Hi all :-)

If possible I'm hoping someone can kindly provide a formula for the following please;

In Z1 I would like a formula to look at the range U6:AJ15 and return the text of the first cell that contains text.

Hope this makes sense :)

Thanks RBW
 

Excel Facts

Did you know Excel offers Filter by Selection?
Add the AutoFilter icon to the Quick Access Toolbar. Select a cell containing Apple, click AutoFilter, and you will get all rows with Apple
One option to try:
Book1
TUVWXYZAA
1z<-scan by row
2x<- scan by column
3
4
5
6z
7xcd
8kk
9
Sheet5
Cell Formulas
RangeFormula
Z1Z1=LET(t,U6:X8,s,SEQUENCE(ROWS(t),COLUMNS(t)),CONCAT(IF(s=MIN(IF((t<>""),s,"")),t,"")))
Z2Z2=LET(t,TRANSPOSE(U6:X8&""),s,SEQUENCE(ROWS(t),COLUMNS(t)),CONCAT(IF(s=MIN(IF(t<>"",s,"")),t,"")))
 
Upvote 0
Solution
For scanning by column, how about: =INDEX(TOCOL(U6:X8,1,TRUE),1)

For scanning by row: =INDEX(TOCOL(U6:X8,1),1)
 
Upvote 0
It was for the 2021 web/online version only - I think.
Screen Shot 2025-01-17 at 3.24.14 PM.png
 
Upvote 0
One option to try:
Book1
TUVWXYZAA
1z<-scan by row
2x<- scan by column
3
4
5
6z
7xcd
8kk
9
Sheet5
Cell Formulas
RangeFormula
Z1Z1=LET(t,U6:X8,s,SEQUENCE(ROWS(t),COLUMNS(t)),CONCAT(IF(s=MIN(IF((t<>""),s,"")),t,"")))
Z2Z2=LET(t,TRANSPOSE(U6:X8&""),s,SEQUENCE(ROWS(t),COLUMNS(t)),CONCAT(IF(s=MIN(IF(t<>"",s,"")),t,"")))

Works perfectly thank you :)
 
Upvote 0
Hi all :-)

If possible I'm hoping someone can kindly provide a formula for the following please;

In Z1 I would like a formula to look at the range U6:AJ15 and return the text of the first cell that contains text.

Hope this makes sense :)

Thanks RBW
Does this work for you?

Compare two ranges in Excel to see if they match exactly.xlsm
TUVWXYZAAABACAD
1z<-scan by row
2x<- scan by column
3
4
5
6z
7xcd
8kk
9
10
Sheet2
Cell Formulas
RangeFormula
Z1Z1=LEFT(TEXTJOIN("",TRUE,U6:X8),1)
Z2Z2=LEFT(TEXTJOIN("",TRUE,TRANSPOSE(IF(U6:X8="","",U6:X8))),1)
 
Upvote 0

Forum statistics

Threads
1,225,606
Messages
6,185,957
Members
453,333
Latest member
BioCoder84

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