Formula for looking up value based on number of characters

art1884

New Member
Joined
May 19, 2018
Messages
7
Hello all,

I need assistance with a formula that looks up a value in different sheet based on the number of characters in the cell. for example, I have a list on sheet 2. In sheet1 A1, I need to be able to type 6 (any number, 6 is just an example). I need the formula to look for all words in sheet2 list that contain 6 characters. lastly, if its possible to display the results in a drop down list which will preserve space. thank you all for you help.
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
Are the words in Sheet2 all in column A or throughout the sheet in various columns and rows?
 
Upvote 0
Hi Art1884,

Does this do what you ask?

art1884.xlsx
A
1List
2Dog
3Elephant
4Dexter
5Charlie
6Sharon
7Paul
Sheet2


art1884.xlsx
A
16
2Dexter
3Sharon
4 
5 
6 
7 
Sheet1
Cell Formulas
RangeFormula
A2:A7A2=IFERROR(INDEX(Sheet2!$A$2:$A$9999,AGGREGATE(15,6,ROW(Sheet2!$A$2:$A$9999)-ROW(Sheet2!$A$1)/(LEN(Sheet2!$A$2:$A$9999)=$A$1),ROW()-ROW($A$1))),"")
 
Upvote 0
Alternatively, maybe...assumes you're running 365 which you didn't specify.

Book1
ABC
16Words Sheet
2policecriticism
3injurypolice
4growthargument
5orangeproblem
6cookieinjury
7philosophy
8soup
9surgery
10heart
11growth
12orange
13performance
14lake
15gate
16science
17currency
18finding
19baseball
20salad
21cookie
SearchWords
Cell Formulas
RangeFormula
A2:A6A2=FILTER(Words!A1:A20,A1=LEN(Words!A1:A20),"")
Dynamic array formulas.
 
Upvote 0
Alternatively, maybe...assumes you're running 365 which you didn't specify.

Book1
ABC
16Words Sheet
2policecriticism
3injurypolice
4growthargument
5orangeproblem
6cookieinjury
7philosophy
8soup
9surgery
10heart
11growth
12orange
13performance
14lake
15gate
16science
17currency
18finding
19baseball
20salad
21cookie
SearchWords
Cell Formulas
RangeFormula
A2:A6A2=FILTER(Words!A1:A20,A1=LEN(Words!A1:A20),"")
Dynamic array formulas.
I truly appreciate the help, I didn’t realized the difference of 365.
 
Upvote 0

Forum statistics

Threads
1,214,983
Messages
6,122,588
Members
449,089
Latest member
Motoracer88

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